Skip to content

shoov/test-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Preface

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:

shoov_gizra_com__code_3a94afa481685398b62e__screenshots_12

Remember that Shoov is still in early stages so be gentle. Or contribute a PR.

Installation

  1. Login to Shoov and copy/ paste the code from on the My account page, in order to get your access token
  2. Fork this repo, and clone it
  3. Install mocha globally npm install -g mocha
  4. Follow installation notes for WebdriverCss
  5. cd test-example && npm install

Providers

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>

Usage

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.

Credits

Gizra

Releases

No releases published

Packages

No packages published