Hello Everyone,
-- We are writing integration tests using Selenium Web Driver and Cucumber JVM for our GWT application.
One major issue that we are facing is how to identify when all the Async calls are complete. We would like to execute the next Step only after all the async calls are complete from the previous step.
Currently, because there is no control over the same, the test results are in-consistent. Sometimes because the async call from earlier step gets completed during a step we get Selenium's StaleElementReferenceException because of the DOM refresh caused by the async call.
I have seen posts which mention to use WebDriverwait with a timeout enough to wait for the elements to be located. We are already doing that......That does not solve the problem in a generic manner.
What I am looking for is a generic solution which will enable me to wait for the completion of all the async calls which I can use in between the steps. This way the test results will be consistent.
I tried different options like
- document.readyState to become "complete"
- jQuery.active != 0 etc.
But none of these identify whether all the async calls are finished.
I also saw the post - https://gist.github.com/jlindsey/424127 and am going to try out the same.....
Is there any tried and tested approach for the same which has been used across GWT applications?
Thanks in advance,
Ranjith
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.
No comments:
Post a Comment