### Question:
SystemDataMeta extends BaseTransformMeta implements ITransform { @Override public String getXml() { StringBuilder retval = new StringBuilder(); retval.append( " <fields>" + Const.CR ); for ( int i = 0; i < fieldName.length; i++ ) { retval.append( " <field>" + Const.CR ); retval.append( " " + XmlHandler.addTagValue( "name", fieldName[ i ] ) ); retval.append( " " + XmlHandler.addTagValue( "type", fieldType[ i ] != null ? fieldType[ i ].getCode() : "" ) ); retval.append( " </field>" + Const.CR ); } retval.append( " </fields>" + Const.CR ); return retval.toString(); } SystemDataMeta(); String[] getFieldName(); void setFieldName( String[] fieldName ); SystemDataTypes[] getFieldType(); void setFieldType( SystemDataTypes[] fieldType ); @Override void loadXml( Node transformNode, IHopMetadataProvider metadataProvider ); void allocate( int count ); @Override Object clone(); @Override void setDefault(); @Override void getFields( IRowMeta row, String name, IRowMeta[] info, TransformMeta nextTransform,
                         IVariables variables, IHopMetadataProvider metadataProvider ); @Override String getXml(); @Override void check( List<ICheckResult> remarks, PipelineMeta pipelineMeta, TransformMeta transformMeta,
                     IRowMeta prev, String[] input, String[] output, IRowMeta info, IVariables variables,
                     IHopMetadataProvider metadataProvider ); @Override ITransform getTransform( TransformMeta transformMeta, ITransformData data, int cnr,
                                PipelineMeta pipelineMeta, Pipeline pipeline ); @Override ITransformData getTransformData(); @Override boolean equals( Object o ); @Override int hashCode();  }### Answer:
@Test public void testGetXML() throws Exception { String generatedXML = expectedSystemDataMeta.getXml(); assertEquals( expectedXML.replaceAll( "\n", "" ).replaceAll( "\r", "" ), generatedXML.replaceAll( "\n", "" ) .replaceAll( "\r", "" ) ); }