ActionConverter extends AbstractTestActionConverter<Object, TestAction> { @Override public Object convertModel(TestAction model) { ActionModel action = new ObjectFactory().createActionModel(); action.setReference(model.getName()); action.setDescription(model.getDescription()); return action; } ActionConverter(String actionType); @Override Object convertModel(TestAction model); @Override Class<Object> getSourceModelClass(); @Override Class<TestActionModel> getTargetModelClass(); @Override Class<com.consol.citrus.TestAction> getActionModelClass();  }
@Test(dataProvider = "converterData") public void testConvert(TestActionConverter actionConverter, ModelAndAssertion modelAndAssertion) throws Exception { TestActionModel result = actionConverter.convert(modelAndAssertion.getModel()); modelAndAssertion.assertModel(result); Object modelConversion = actionConverter.convertModel(modelAndAssertion.getAction()); Assert.assertEquals(modelConversion.getClass(), modelAndAssertion.getModel().getClass()); modelAndAssertion.assertModel(modelConversion); }