BAEL-2990 Automatic generation of the Builder pattern with FreeBuilder
This commit is contained in:
parent
3b3a0fcd67
commit
f71224ed2c
|
@ -86,13 +86,14 @@ public class EmployeeBuilderUnitTest {
|
||||||
.setEmail("abc@xyz.com")
|
.setEmail("abc@xyz.com")
|
||||||
.setSupervisorName("Admin")
|
.setSupervisorName("Admin")
|
||||||
.setPhoneNumber(4445566)
|
.setPhoneNumber(4445566)
|
||||||
.setNullablePermanent(null)
|
.setPermanent(true)
|
||||||
.setDateOfJoining(Optional.empty())
|
|
||||||
.setRole("developer")
|
.setRole("developer")
|
||||||
.setAddress(address)
|
.setAddress(address)
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
// then
|
// then
|
||||||
|
assertTrue(employee.getPermanent().isPresent());
|
||||||
|
assertTrue(employee.getPermanent().get());
|
||||||
assertFalse(employee.getDateOfJoining().isPresent());
|
assertFalse(employee.getDateOfJoining().isPresent());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue