Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
test WebDriverWait
# 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