-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #49 from browserstack/selenium-4
Selenium 4 to master
- Loading branch information
Showing
2 changed files
with
64 additions
and
94 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,111 +1,81 @@ | ||
module.exports = { | ||
// An array of folders (excluding subfolders) where your tests are located; | ||
// if this is not specified, the test source must be passed as the second argument to the test runner. | ||
src_folders: [], | ||
const bstackOptions = { | ||
'bstack:options' : { | ||
"os" : "OS X", | ||
"osVersion" : "Sierra", | ||
"buildName" : "Final-Snippet-Test", | ||
"sessionName" : "Selenium-4 Nodejs snippet test", | ||
"local" : "false", | ||
"seleniumVersion" : "4.0.0", | ||
userName: '${BROWSERSTACK_USERNAME}', | ||
accessKey: '${BROWSERSTACK_ACCESS_KEY}', | ||
}, | ||
} | ||
|
||
// See https://nightwatchjs.org/guide/working-with-page-objects/using-page-objects.html | ||
page_objects_path: ['node_modules/nightwatch/examples/pages/'], | ||
|
||
// See https://nightwatchjs.org/guide/extending-nightwatch/custom-commands.html | ||
custom_commands_path: ['node_modules/nightwatch/examples/custom-commands/'], | ||
const browserStack = { | ||
webdriver: { | ||
start_process: false | ||
}, | ||
|
||
// See https://nightwatchjs.org/guide/extending-nightwatch/custom-assertions.html | ||
custom_assertions_path: '', | ||
selenium: { | ||
host: 'hub-cloud.browserstack.com', | ||
port: 443 | ||
}, | ||
|
||
// See https://nightwatchjs.org/guide/extending-nightwatch/plugin-api.html | ||
plugins: [], | ||
|
||
// See https://nightwatchjs.org/guide/#external-globals | ||
globals_path : '', | ||
desiredCapabilities: { | ||
browserName: 'chrome', | ||
...bstackOptions | ||
} | ||
} | ||
|
||
webdriver: {}, | ||
module.exports = { | ||
src_folders: [], | ||
|
||
test_settings: { | ||
////////////////////////////////////////////////////////////////////////////////// | ||
// Please set the username and access key by setting the environment variables: | | ||
// - BROWSERSTACK_USERNAME | | ||
// - BROWSERSTACK_ACCESS_KEY | | ||
// .env files are supported | | ||
////////////////////////////////////////////////////////////////////////////////// | ||
browserstack: { | ||
selenium: { | ||
host: 'hub.browserstack.com', | ||
port: 443 | ||
}, | ||
// More info on configuring capabilities can be found on: | ||
// https://www.browserstack.com/automate/capabilities?tag=selenium-4 | ||
desiredCapabilities: { | ||
'bstack:options' : { | ||
userName: '${BROWSERSTACK_USERNAME}', | ||
accessKey: '${BROWSERSTACK_ACCESS_KEY}', | ||
buildName: 'browserstack-build-1' | ||
}, | ||
browserName: 'chrome', | ||
browserVersion: 'latest' | ||
}, | ||
|
||
disable_error_log: true, | ||
webdriver: { | ||
timeout_options: { | ||
timeout: 120000, | ||
retry_attempts: 3 | ||
}, | ||
keep_alive: true, | ||
start_process: false | ||
} | ||
default: { | ||
launch_url: 'https://nightwatchjs.org' | ||
}, | ||
|
||
'browserstack.local': { | ||
extends: 'browserstack', | ||
desiredCapabilities: { | ||
'browserstack.local': true | ||
} | ||
browserstack: { | ||
...browserStack | ||
}, | ||
|
||
'browserstack.chrome': { | ||
extends: 'browserstack', | ||
desiredCapabilities: { | ||
browserName: 'chrome', | ||
chromeOptions : { | ||
w3c: true | ||
} | ||
"browserstack.chrome": { | ||
...browserStack, | ||
desiredCapabilities:{ | ||
browserName: 'chrome', | ||
...bstackOptions | ||
} | ||
}, | ||
|
||
'browserstack.firefox': { | ||
extends: 'browserstack', | ||
desiredCapabilities: { | ||
browserName: 'firefox' | ||
"browserstack.firefox": { | ||
...browserStack, | ||
desiredCapabilities:{ | ||
browserName: 'firefox', | ||
...bstackOptions | ||
} | ||
}, | ||
|
||
'browserstack.ie': { | ||
extends: 'browserstack', | ||
desiredCapabilities: { | ||
browserName: 'internet explorer', | ||
browserVersion: '11.0' | ||
} | ||
}, | ||
|
||
'browserstack.safari': { | ||
extends: 'browserstack', | ||
desiredCapabilities: { | ||
browserName: 'safari' | ||
"browserstack.edge": { | ||
...browserStack, | ||
desiredCapabilities:{ | ||
browserName: 'Edge', | ||
...bstackOptions | ||
} | ||
}, | ||
|
||
'browserstack.local_chrome': { | ||
extends: 'browserstack.local', | ||
desiredCapabilities: { | ||
browserName: 'chrome' | ||
} | ||
}, | ||
|
||
'browserstack.local_firefox': { | ||
extends: 'browserstack.local', | ||
// capabilities to run local test on BrowserStack | ||
'browserstack.local': { | ||
...browserStack, | ||
desiredCapabilities: { | ||
browserName: 'firefox' | ||
} | ||
}, | ||
browserName: 'chrome', | ||
'bstack:options' : { | ||
"os" : "OS X", | ||
"osVersion" : "Sierra", | ||
"buildName" : "Final-Snippet-Test", | ||
"sessionName" : "Selenium-4 Nodejs snippet test", | ||
"local" : "true", | ||
"seleniumVersion" : "4.0.0", | ||
userName: '${BROWSERSTACK_USER}', | ||
accessKey: '${BROWSERSTACK_KEY}', | ||
}, | ||
} | ||
} | ||
} | ||
}; | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.