.extracting("surname")
.containsNull();
assertThat(employees).as("null nested field")
.extracting("surname.first")
.containsNull();
yoda.surname = new Name();
assertThat(employees).as("not null field but null nested field")
.extracting("surname.first")
.containsNull();
yoda.surname = new Name("Master");
assertThat(employees).as("nested field")
.extracting("surname.first")
.containsOnly("Master", null);
assertThat(employees).as("extract field specifiying the extracted type")
.extracting("surname", Name.class)
.containsOnly(new Name("Master"), null);
}