Tapestry5.1+seleniumRc Ajax waitForAjax Request
Does anyone know how to do waitForAjaxRequest using seleniumRc (like waitForPageToLoad) on tapestry zone? I know there are alternatives like wait for certain element to appear and etc.
I am seeking for a proper waitForAjaxRequest, and wish it work on different browsers as wel开发者_JS百科l.
I had tried browserbot, but no luck.
You can use waitForCondition:
selenium.waitForCondition("script", "timeout")
while timeout is in milliseconds (e.g. 30000) and the script is JavaScript that has to return true when the condition is fulfilled, e.g.
"var value = selenium.getText('foo'); value.match(/bar/);"
(See OpenQA Wiki for more information. Even though this links to a plugin that was in use with an older version of Selenium, waitForCondition is now part of SeleniumRC.)
加载中,请稍侯......
精彩评论