Modify Optional value to be more descriptive

This commit is contained in:
danielmcnally285 2023-11-05 20:11:49 +00:00
parent 5cc111ee48
commit a8e298e389
1 changed files with 2 additions and 2 deletions

View File

@ -15,7 +15,7 @@ public class ReturnFirstNonEmptyOptionalUnitTest {
@BeforeEach
public void init() {
optionals = Arrays.asList(Optional.<String> empty(), Optional.of("first non null"), Optional.of("second non null"));
optionals = Arrays.asList(Optional.<String> empty(), Optional.of("first non empty"), Optional.of("second non empty"));
}
@Test
@ -25,6 +25,6 @@ public class ReturnFirstNonEmptyOptionalUnitTest {
.map(Optional::get)
.findFirst();
assertThat(object).contains("first non null");
assertThat(object).contains("first non empty");
}
}