Hi all

I'm still experimenting with ways to make it easier to write (or
combine) custom ElementSelectors.  It occured to me it might be useful
for an ElementSelector to not only know the Elements it is supposed to
evaluate but also their position inside the respective documents.  In
the branch https://github.com/xmlunit/xmlunit/tree/two-arg-element-selector
I've modified the signature to be

    boolean canBeCompared(Element controlElement, XPathContext controlXPath,
                              Element testElement, XPathContext testXPath);

which also meant I had to modify NodeMatcher's interface.  The branch
still isn't complete - ElementSelectors#byXPath doesn't properly
provide the XPathContexts for the NodeMatcher it uses internally - but
close enough to ask for comments now.  Unless anything significant
happens, I should be able to complete the branch today.

Is this a good idea or am I just adding complexity without gaining too
much?  Any feedback is more than welcome

Cheers

        Stefan

[In case you've been following along: I cherry-picked some refactorings
from and then rebased the branch, sorry for the noise.]


------------------------------------------------------------------------------
One dashboard for servers and applications across Physical-Virtual-Cloud 
Widest out-of-the-box monitoring support with 50+ applications
Performance metrics, stats and reports that give you Actionable Insights
Deep dive visibility with transaction tracing using APM Insight.
http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
_______________________________________________
Xmlunit-general mailing list
Xmlunit-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xmlunit-general

Reply via email to