[Webtest] Re: richFaces Ajax + content not updated (Keusch Florian)

Paul Beck Paul Beck" <pbeck@nearinfinity.com
Wed, 9 Jul 2008 12:15:15 -0400


It appears this is the same issue I was seeing attempting to use
WebTest against the Petstore 2.0 application. The suggested solution
to use <verifyXPath> does not seem viable, as what I want to do is to
verify the content displayed, not the existence/validity of a link or
object on the page. Perhaps I don't understand how <verifyXPath>
works. At any rate, since Watir and Selenium handle this situation
quite nicely by inserting a pause/sleep to wait for the content to be
rendered, I don't understand why WebTest cannot work the same. As I
noted in a prior post, if you attempt to cause WebTest to wait for the
completed response by inserting a <sleep> or by setting the <config>
option "easyAjax", WebTest will go into a loop.

Paul Beck

> Date: Wed, 9 Jul 2008 12:55:44 +0200
> From: "Keusch Florian" <florian.keusch@elca.ch>
> To: <webtest@lists.canoo.com>
> Subject: [Webtest] Re: richFaces Ajax + content not updated
> Reply-To: webtest@lists.canoo.com
> Reply-To: "Keusch Florian" <florian.keusch@elca.ch>
> hi,
> i've a simple test applied on the richFaces demo to show this problem:
> <webtest name=3D"richFaces demo - test ajax commandButton">
>   <invoke
> url=3D"http://livedemo.exadel.com/richfaces-demo/richfaces/commandButton.=
> jsf?c=3DcommandButton"/>
>   <setInputField name=3D"j_id221:j_id224" value=3D"florian"/>
>   <clickButton label=3D"Say Hello" name=3D"j_id221:j_id225"/>
>   <verifyText description=3D"Verify that text is contained in the page"
> text=3D"Hello florian! "/>
> </webtest>
> You'll see that the step verifyText fails because the page content was
> not updated! I used a http proxy=20
> Using webtest r_1710 (with htmlunit 2.1)
> Greetings Florian
> --__--__--