* Tests comparison will reset XPath after recursion.
*
* @throws Exception unexpected
*/
public void testWillResetXPathAfterRecursion() throws Exception {
XppDom dom1 = XppFactory.buildDom("<dom><a><b>foo</b></a><c x='1'/></dom>");
XppDom dom2 = XppFactory.buildDom("<dom><a><b>foo</b></a><c x='2'/></dom>");
assertEquals(-1, comparator.compare(dom1, dom2));
assertEquals("/dom/c[0][@x]", xpath.get());
assertEquals(1, comparator.compare(dom2, dom1));
assertEquals("/dom/c[0][@x]", xpath.get());
}