use of org.pentaho.di.trans.steps.normaliser.NormaliserMeta in project pentaho-kettle by pentaho.
the class NormalizerMetaTest method loadSaveTest.
@Test
public void loadSaveTest() throws KettleException {
List<String> attributes = Arrays.asList("normaliserFields");
NormaliserField testField = new NormaliserField();
testField.setName("TEST_NAME");
testField.setValue("TEST_VALUE");
testField.setNorm("TEST");
Map<String, FieldLoadSaveValidator<?>> fieldLoadSaveValidatorTypeMap = new HashMap<String, FieldLoadSaveValidator<?>>();
fieldLoadSaveValidatorTypeMap.put(NormaliserField[].class.getCanonicalName(), new ArrayLoadSaveValidator<NormaliserField>(new NormaliserFieldLoadSaveValidator(testField), 50));
LoadSaveTester<NormaliserMeta> tester = new LoadSaveTester<NormaliserMeta>(NormaliserMeta.class, attributes, new HashMap<String, String>(), new HashMap<String, String>(), new HashMap<String, FieldLoadSaveValidator<?>>(), fieldLoadSaveValidatorTypeMap);
tester.testSerialization();
}
Aggregations