Modify Optional value to be more descriptive
This commit is contained in:
parent
5cc111ee48
commit
a8e298e389
@ -15,7 +15,7 @@ public class ReturnFirstNonEmptyOptionalUnitTest {
|
|||||||
|
|
||||||
@BeforeEach
|
@BeforeEach
|
||||||
public void init() {
|
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
|
@Test
|
||||||
@ -25,6 +25,6 @@ public class ReturnFirstNonEmptyOptionalUnitTest {
|
|||||||
.map(Optional::get)
|
.map(Optional::get)
|
||||||
.findFirst();
|
.findFirst();
|
||||||
|
|
||||||
assertThat(object).contains("first non null");
|
assertThat(object).contains("first non empty");
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user