Exemple #1
0
  private void assertLocalConfigurationWasApplied(final ClassWithIPerson classWithPerson) {

    assertTrue(
        "must be configured to be instance of Person",
        classWithPerson.getPerson() instanceof Person);
    assertNotNull("instance must be generated", classWithPerson.getPerson() instanceof Person);
  }
Exemple #2
0
  @Test
  public void testConfigurationWillBeMerged() {
    final ClassWithIPerson classWithPerson =
        ObjectG.unique(ClassWithIPerson.class, ObjectG.config().when(Tour.class).setValue(null));

    assertLocalConfigurationWasApplied(classWithPerson);
    assertNull(classWithPerson.getTour());
  }