@Test public void canAssembleASmurfRFromASmurfEntity() throws Exception { LocalDate now = LocalDate.now(); Smurf smurf = SmurfTestBuilder.aDefaultSmurf().withCreationDate(now).build(); SmurfR smurfR = SmurfAssembler.toRepresentation(smurf); SmurfR expectedSmurfR = SmurfRTestBuilder.aSmurfR() .withName(SmurfTestBuilder.NAME) .withCreationDate(now) .build(); assertThat(smurfR).isEqualTo(expectedSmurfR); }
public static SmurfR toRepresentation(Smurf smurf) { return new SmurfR(smurf.getId(), smurf.getName(), smurf.getCreationDate()); }
SmurfAssembler { public static SmurfR toRepresentation(Smurf smurf) { return new SmurfR(smurf.getId(), smurf.getName(), smurf.getCreationDate()); } }
SmurfAssembler { public static SmurfR toRepresentation(Smurf smurf) { return new SmurfR(smurf.getId(), smurf.getName(), smurf.getCreationDate()); }  }
SmurfAssembler { public static SmurfR toRepresentation(Smurf smurf) { return new SmurfR(smurf.getId(), smurf.getName(), smurf.getCreationDate()); }  static SmurfR toRepresentation(Smurf smurf); }
SmurfAssembler { public static SmurfR toRepresentation(Smurf smurf) { return new SmurfR(smurf.getId(), smurf.getName(), smurf.getCreationDate()); }  static SmurfR toRepresentation(Smurf smurf);  }