Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(177)

Unified Diff: third_party/webdriver/py/selenium/remote/webdriver/WebDriver.py

Issue 3643002: Implemnts the commands in webdriver to preform searching of elements on a page. (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: fix for windows build Created 10 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/webdriver/py/selenium/remote/webdriver/WebDriver.py
diff --git a/third_party/webdriver/py/selenium/remote/webdriver/WebDriver.py b/third_party/webdriver/py/selenium/remote/webdriver/WebDriver.py
index b7246a00cada11d4752eb459d7c3fe30152b2548..35bff2ed2374f3d564fe3a6526ea9b31ae54eeaf 100644
--- a/third_party/webdriver/py/selenium/remote/webdriver/WebDriver.py
+++ b/third_party/webdriver/py/selenium/remote/webdriver/WebDriver.py
@@ -173,6 +173,17 @@ class WebDriver(object):
resp = self._execute(Command.GET_TITLE)
return resp['value']
+ def set_implicit_wait(self, wait):
+ """Set the amount of time the driver should wait when searching for
+ elements. When searching for a single element, the driver should poll
+ the page until an element is found or the timeout expires, whichever
+ occurs first. When searching for multiple elements, the driver should
+ poll the page until at least one element is found or the timeout
+ expires, at which point it should return an empty list. If this
+ command is never sent, the driver should default to an implicit wait
+ of 0ms."""
+ self._execute(Command.IMPLICIT_WAIT, {'ms': wait})
+
def find_element_by_id(self, id_):
"""Finds element by id."""
return self._find_element_by("id", id_)
« no previous file with comments | « chrome/test/webdriver/webdriver_remote_tests.py ('k') | third_party/webdriver/py/selenium/remote/webdriver/command.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698