Authenticate with Sauce Labs
SAUCE_ACCESS_KEY environment variables to authenticate with Sauce Labs.
All CI tools provide a way to set environment variables for a test run. For non-CI test runs, set the environment variables in your shell or in your test runner script.
Pick the browsers to run against
Rather than exhaustively list every permutation of devices, operating systems, and browsers, we use a shorthand to match all the platforms we target.
plugins: sauce_labs: browsers: # Internet Explorer 11 on every device and operating system it supports. IE: 11 # Latest two Chrome releases on all Mac and Windows platforms: Google Chrome: os: Mac, Windows version: -2 # Latest two Firefox releases on every platform: Firefox: version: -2 # Latest Safari release on every Mac platform (OS X 10.x): Safari: platform: Mac version: -1 # Latest two Edge releases on every platform: Microsoft Edge: version: -2 # Specific iOS Mobile Safari versions: iPhone: version: [9.2, 8.4] # Mobile-specific browser: Motorola Droid 4 Emulator: version: [5.1, 4.4]
See Sauce Labs' Platform Configurator for an exhaustive list of supported devices, operating systems, and browsers.
For low-level Sauce Connect configuration, set
tunnel_args to an array of command line arguments.
plugins: sauce_labs: tunnel_args: - "--verbose" # Turn on verbose logging. - "--vm-version" # Use the varnish VM for WebSockets support. - "dev-varnish"
The plugin already sets the
--readyfile arguments, so don't set these yourself.