GenderTypeResourceConverter extends AbstractConverter<GenderTypeResource, GenderType> { @Override public GenderType convert(final GenderTypeResource source, final GenderType target) { target.setName(source.getName()); target.setAbbrName(source.getAbbrName()); return target; }  @Override GenderType convert(final GenderTypeResource source, final GenderType target); @Override GenderType convert(final GenderTypeResource source);  }
@Test public void testConvert() throws Exception { String name = "first blood"; String abbrName = "fb"; GenderType expected = new GenderType(); expected.setName(name); expected.setAbbrName(abbrName); GenderTypeResource source = new GenderTypeResource(); source.setName(name); source.setAbbrName(abbrName); GenderType actual = unit.convert(source); assertEquals(expected, actual); }