appium
Version:
Automation for Apps.
85 lines (75 loc) • 2.78 kB
YAML
name: Set Implicit Wait Timeout
short_description: Set the amount of time the driver should wait when searching for elements
description:
|
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
example_usage:
java:
|
driver.manage().timeouts().implicitlyWait(30, TimeUnit.SECONDS);
python:
|
self.driver.implicitly_wait(5000)
javascript_wd:
|
await driver.setImplicitWaitTimeout(5000);
javascript_wdio:
|
driver.timeoutsImplicitWait(5000)
ruby:
|
@driver.manage.timeouts.implicit_wait = 5 # Ruby translates it to seconds
php:
|
// TODO PHP sample
csharp:
|
// TODO C# sample
client_docs:
java: "https://seleniumhq.github.io/selenium/docs/api/java/org/openqa/selenium/remote/RemoteWebDriver.RemoteWebDriverOptions.RemoteTimeouts.html#implicitlyWait-long-java.util.concurrent.TimeUnit-"
python: "http://selenium-python.readthedocs.io/api.html#selenium.webdriver.remote.webdriver.WebDriver.implicitly_wait"
javascript_wdio: "http://webdriver.io/api/protocol/timeoutsImplicitWait.html#description"
javascript_wd: "https://github.com/admc/wd/blob/master/lib/commands.js#L681"
ruby: "http://www.rubydoc.info/gems/selenium-webdriver/Selenium/WebDriver/Timeouts:implicit_wait="
php: "https://github.com/appium/php-client/" # TODO PHP documentation link
csharp: "https://github.com/appium/appium-dotnet-driver/" # TODO Dotnet documentation link
# Driver support by platform
driver_support:
ios:
xcuitest: true
uiautomation: true
android:
uiautomator2: true
uiautomator: true
mac:
mac: true
windows:
windows: true
client_support:
java: true
python: true
ruby: true
php: true
csharp: true
javascript_wd: true
javascript_wdio: true
# Information about the HTTP endpoints
endpoint:
url: /session/:session_id/timeouts/implicit_wait
method: POST
url_parameters:
- name: session_id
description: ID of the session to route the command to
json_parameters:
- name: ms
type: number
description: The amount of time, in milliseconds, that time-limited commands are permitted to run
# Links to specifications. Should link to at least one specification
specifications:
w3c: https://www.w3.org/TR/webdriver/#dfn-get-timeouts
jsonwp: https://github.com/SeleniumHQ/selenium/wiki/JsonWireProtocol#sessionsessionidtimeoutsimplicit_wait