Don't clone this repo, but fork it - as Shoov is aware to the repository name, so for the sake of the example, we want to make sure your test is unique
The end results looks like this:
Remember that Shoov is still in early stages so be gentle. Or contribute a PR.
- Login to Shoov and copy/ paste the code from on the
My account
page, in order to get your access token - Fork this repo, and clone it
- Install mocha globally
npm install -g mocha
- Follow installation notes for WebdriverCss
npm install
For local testing use phantomJs phantomjs --webdriver=4444
Otherwise you can use BrowserStack or Sauce Labs:
# Set BrowserStack keys
export BROWSERSTACK_USERNAME=<username>
export BROWSERSTACK_KEY=<token>
OR
# Set Suace Labs keys
export SAUCE_USERNAME=<username>
export SAUCE_ACCESS_KEY=<token>
mocha
will tests all the files under the test
folder.
The example file shows how a single test file can be executed under multiple platforms and browsers. Assuming we are using browserstack, this can be executed by passing the environment argument like this:
# Execute the tests using the ie11 config.
PROVIDER_PREFIX=browserstack SELECTED_CAPS=ie11 mocha
# Execute the tests using the chrome on Mac config.
PROVIDER_PREFIX=browserstack SELECTED_CAPS=chrome mocha
# Execute the tests with the default capabilities provided by the `shoov-webdrivercss` library.
mocha
After a regression was found check your Builds page, or go directly to the link indicated by the failing Mocha test.