Feature Requests item #1236619, was opened at 2005-07-12 11:49
Message generated for change (Comment added) made by henryju
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=497985&aid=1236619&group_id=61302
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
>Status: Closed
Priority: 5
Submitted By: Dennis Cheung (hkdennis2k)
Assigned to: Nobody/Anonymous (nobody)
Summary: content assertion in XPath
Initial Comment:
I think, using assertTextPresent / assertTextNotPresent
/ assertTextInTable are foolish.
There is too complex and difficult to do test many cases.
But, there are one easy solution.
make jwebunit also use DOM/XPath for content assertion.
In many common website, we don't add unique id into
every table we have. But, always have a DOM tree.
e.g.
assertTablePresent("tableid");
can replace by
assertContentExists("//[EMAIL PROTECTED]'tableid']");
but, we can do many more, in easy way, without create
numebers of method in API.
assertNodeExists("//[EMAIL PROTECTED]'contentarea']/*/[EMAIL
PROTECTED]'tableid']");
Why not I just use XPath? because I use others feature
provide by jwebunit.
----------------------------------------------------------------------
>Comment By: Julien HENRY (henryju)
Date: 2006-06-02 23:51
Message:
Logged In: YES
user_id=1235926
assertElementPresentByXPath is a new method that should do
what you suggest. But only HtmlUnitDialog and SeleniumDialog
implement it.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=497985&aid=1236619&group_id=61302
_______________________________________________
Jwebunit-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jwebunit-development