@Test public void should_create_new_Index() { Index index = Index.atIndex(8); assertEquals(8, index.value); }
@Test public void should_throw_error_if_value_is_negative() { thrown.expectIllegalArgumentException("The value of the index should not be negative"); Index.atIndex(-1); }