Herein lies an example Protractor project, that includes tests (some quite silly) that aim to illustrate solutions for common issues when writing e2e tests.
- Makes use of page objects
- Runs tests on Sauce Labs
- Runs multiple browsers at once
- Runs tests sharded (parallel)
- Includes examples tests for both Angular, and non-Angular applications
- Uses protractor-flake to re-run failed tests
- is written using es6
- Install Node (v8.x.x or later)
git clone [email protected]:qualityshepherd/protractor-example.gitnpm ito install the project dependencies
- run tests via plain Protractor
node_modules/.bin/protractor conf.js - run tests
npm test(runs via flake, which re-runs failed tests) - run with flake
./flake conf.js - run on saucelabs
./flake sauceConf.js(add your username/key)
Or if you're a non-reader, watch the video...
- run
node -vand make sure your node version is 8.x.x or greater webdriver-managershould have updated on install, but if not, runnpm run updateto be sure