Hi Robert,
what does provoke the Java Script to load the "real" page?
You might execute this action with groovy:
<groovy description="execute on blur on element" replaceProperties="true" >
step.context.currentResponse.getHtmlElementById('successRateAdjustPerc_101_#{projection_unit_id}').fireEvent("blur")
</groovy>
So your webtest will do the same you application/browser does.
With kind regards
Michael Habbert
[...]
I'm testing an ExtJS application. The HTML loaded has no content other than a
reference to the ExtJS Javascript code. So if I just use <invoke> to load my
page its initially blank until the Javascript has a second to update it. Using
sleep results in the following message...
"Content of window changed with javascript, it will NOT become current response"
However, that is exactly what I want, I want the javascript change to become
the current response. How do I do that??
<target name="wt.testInWork">
<webtest name="my simple Test">
<steps>
<invoke
url="http://localhost:8080/development/commonComponents/superfield/test.html"
description="Go to Google (in English)"/>
<sleep seconds="30"/>
<verifyText text="SuperField"/> <--- only available after the
Javascript has a few seconds to run
</steps>
</webtest>
</target>
-Robert
Michael Habbert
Key-Work Consulting GmbH | Kriegsstr. 100 | 76133 Karlsruhe | Germany |
www.key-work.de<http://www.key-work.de>
Fon: +49-721-78203-269 | E-Mail:
[email protected]<mailto:[email protected]> | Fax:
+49-721-78203-10
Key-Work Consulting GmbH, Karlsruhe, HRB 108695, HRG Mannheim
Geschäftsführer: Andreas Stappert, Tobin Wotring