Rajiv:
I guess you need to wait until the page gets successfully loaded, and
then verify the existence of the element or content in the page.
I too faced the issue and incorporated the following fix :
1. You may achieve this by giving a huge wait or sleep to wait for the
page to get loaded
successfully.But the page can get loaded before the wait ends and
you need to wait
uselessly. So we can go with the second option.
2. Create new keyword (e.g my_wait_for_page_and_verify(elementName,
maxTimeToWait))
in '_init_.py' which should call :
a. self._wait_for_page_to_load(..).
This will wait either until the page
loads sucessfully or either the
maxTimeToload limit crosses.You can give
a max time in this case as it
will skip the wait once the page get
loaded successfully.
b. page_should_contain(elementName)
Cal this keyword after the above keyword
in the new
keyword (my_wait_for_page(...))
If you require the new keyword i have created, please feel free to
contact me back.