EnrolmentForeignTypeResourceConverter extends AbstractConverter<EnrolmentForeignTypeResource, EnrolmentForeignType> { @Override public EnrolmentForeignType convert(final EnrolmentForeignTypeResource source, final EnrolmentForeignType target) { target.setName(source.getName()); target.setAbbrName(source.getAbbrName()); return target; }  @Override EnrolmentForeignType convert(final EnrolmentForeignTypeResource source, final EnrolmentForeignType target); @Override EnrolmentForeignType convert(final EnrolmentForeignTypeResource source);  }
@Test public void testConvert() throws Exception { String name = "EnrolmentForeignN"; String abbrName = "AN"; EnrolmentForeignType expected = new EnrolmentForeignType(); expected.setName(name); expected.setAbbrName(abbrName); EnrolmentForeignTypeResource source = new EnrolmentForeignTypeResource(); source.setName(name); source.setAbbrName(abbrName); EnrolmentForeignType actual = unit.convert(source); assertEquals(expected, actual); }