听起来像XMLUnit的工作
- http://www.xmlunit.org/
- https://github.com/xmlunit
例:
public class SomeTest extends XMLTestCase { @Test public void test() { String xml1 = ... String xml2 = ... XMLUnit.setIgnoreWhitespace(true); // ignore whitespace differences // can also compare xml documents, InputSources, Readers, Diffs assertXMLEqual(xml1, xml2); // assertXMLEquals comes from XMLTestCase }}


