Capabilities
Capabilities
Before we can send any command to the browser we drive we need to create a WebDriver session. This should be always the first step of interaction using the protocol. To create a new session we need to provide some requirements like browserName
, browserVersion
, platformName
. These requirements are called Capabilities
. This is especially important when we interact not directly with a single browser but with a grid of browsers. Using alwaysMatch
property we can provide some strict requirements. If the WebDriver sever can't provide the required features the session creation will fail. Using firstMatch
property we can provide a list of requirements. During session creation the server will pick the first capability it's able to match. firstMatch
can of course be combined with alwaysMatch
to narrow down the selection.
PROPERTIES
alwaysMatch?
: BrowserCapabilityfirstMatch?
: BrowserCapability[]
EXAMPLES
SEE ALSO
BrowserCapability
PROPERTIES
browserName?
: stringbrowserVersion?
: stringplatformName?
: stringacceptInsecureCerts?
: booleanpageLoadStrategy
:'none'
|'eager'
|'normal'
unhandledPromptBehavior
:'dismiss'
|'accept'
|'dismiss and notify'
|'accept and notify'
|'ignore'
goog:chromeOptions?
: ChromeOptionsmoz:firefoxOptions?
: FirefoxOptionsse:ieOptions?
: InternetExplorerOptionsbstack:options?
: BrowserStackOptions
ChromeOptions
PROPERTIES
w3c?
: booleanbinary?
: stringargs?
: string[]
FirefoxOptions
PROPERTIES
binary?
: stringargs?
: string[]profile?
: stringlog?
: objectlevel?
: string
prefs?
: object
SEE ALSO
InternetExplorerOptions
PROPERTIES
ignoreProtectedModeSettings
: booleanignoreZoomSetting
: booleanie.ensureCleanSession
: boolean
BrowserStackOptions
PROPERTIES
os?
: stringosVersion?
: stringsessionName?
: stringbuildName?
: stringprojectName?
: stringdebug?
: booleannetworkLogs?
: booleanlocal?
: booleanseleniumVersion?
: stringsafari?
: objectenablePopups?
: booleanuseSimulator?
: booleanallowAllCookies?
: booleandriver?
: string
Last updated