Created
August 31, 2013 14:17
-
-
Save falsetru/6398515 to your computer and use it in GitHub Desktop.
test WebDriverWait
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# See https://code.google.com/p/selenium/source/browse/py/selenium/webdriver/support/wait.py | |
from selenium import webdriver | |
from selenium.webdriver.support.wait import WebDriverWait | |
driver = webdriver.Firefox() | |
driver.get('http://jsfiddle.net/falsetru/M6tdQ/show/') | |
WebDriverWait(driver, 10).until(lambda driver: driver.find_element_by_id('status').text == 'ready') | |
driver.execute_script('alert("done")') | |
#driver.quit() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
See also http://selenium.googlecode.com/svn/trunk/docs/api/py/webdriver_support/selenium.webdriver.support.wait.html