From: Lanam, J. <jef...@hp...> - 2010-08-20 00:33:48
|
I'm trying to write a DifferenceEngine for XMLUnit 1.3 that will allow or reject differences based on a list of elements specified by the user. I have a simple one working which just compares the element names, but I would like to use XPath expressions for more precise specification. The problem I have is that the Difference.getTestNodeDetail().getXpathLocation() method returns a non-abbreviated expression, but I want the user to be able to use abbreviated syntax. Is there a way to compare two XPath expressions, using the control document as a reference, and determine if they are referencing the same element? XPath is new to me, and I haven't done much with XSLT or Java XML APIs. Thanks for any help. Jeff Lanam Hewlett-Packard |