EmployeeStatusConverter extends AbstractConverter<EmployeeStatus, EmployeeStatusResource> { @Override public EmployeeStatusResource convert(final EmployeeStatus source, final EmployeeStatusResource target) { target.setId(source.getId()); target.setName(source.getName()); target.setAbbrName(source.getAbbrName()); return target; }  @Override EmployeeStatusResource convert(final EmployeeStatus source, final EmployeeStatusResource target); @Override EmployeeStatusResource convert(final EmployeeStatus source);  }
@Test public void testConvert() throws Exception { String name = "DutyN"; String abbrName = "AN"; EmployeeStatus source = new EmployeeStatus(); source.setName(name); source.setAbbrName(abbrName); EmployeeStatusResource expected = new EmployeeStatusResource(); expected.setName(name); expected.setAbbrName(abbrName); EmployeeStatusResource actual = unit.convert(source); assertEquals(expected, actual); }