XMLUnit doesn't appear to support ignoring comments
when doing a diff. This patch will allow test writer
to ignore a set of node types, including Comments, in a
similar fashion as ignoring whitespace.
XMLUnit.setIgnoreWhitespace(true);
XMLUnit.addIgnoreNodeType(org.w3c.dom.Node.COMMENT_NODE);
assertXMLEqual(doc1, doc2);
Attached is patch that adds addIgnoreNodeType,
removeIgnoreNodeType and clearIgnoreNodeType to
XMLUnit, and alters the documents created to remove the
nodes in this set.
-Jason
patch file
Logged In: NO
Sorry, forgot to login. You can contact me at jlk@windchill.com
Logged In: YES
user_id=113148
Originator: NO
I've used a different approach but XMLUnit in CVS can now ignore comments.