Skip to content

Commit

Permalink
chore: Use sauce for Travis tests
Browse files Browse the repository at this point in the history
directConnect was too... err... flakey for our purposes. Sauce will
hopefully be more reliable.
  • Loading branch information
NickTomlin committed Dec 8, 2016
1 parent 19ca355 commit 9cce406
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 55 deletions.
5 changes: 5 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,8 @@ after_success:
- export $(cat .to_export_back)
- npm run semantic-release
script: PROTRACTOR_FLAKE_LOG_LEVEL=debug npm test
addons:
sauce_connect:
username: pluckdeep
jwt:
secure: "YPCvwHU+vzXfC6CCS3il2BJOd8tpcgnUv7VoTOtYXJN9LHw5AvVDTw6D3uqm7A++BeWOPEsGHLYkgBuLtAxzT1gQc0G4Gkg8w8ykkTZMQ+1r3D+i/J1r9GiNyn4PGDy7DIcgU8+TxNh2TG6x+MqU6fhWIeJY4aoht1Ux/DVNnUfk21s5sXJjpn7lnVXGjGeUIqIt1rq9jvpC5XOsBDKdoo/3PICptdm/77Ej4v6K61VU3TNdJ9fvjpA7lVHDv4hfPGO8h3d0aBFxkCAXHUqhNjmpzqH8O5qozU0R4drMSa1wEdGhld77PGs8LNDbCFMfHkOY59A4aYFyEI7iAg+AvlZ1O1rV3UXfWPYzQsWvVJCZgV0WWioXi8ariStc+VRfVp5eVegw9d64vXzmD76p5sJL4Jqs4bHfYleb7MMDHOBJg3JEyowI3IMVqGBSlEbCxUz8fCkSC0a+BbL1xI3amaQNBDv58Fb/ooF78bkAt4uzPYxA005pGzudVgSKVGspXpDpkwhANGH9kbZRTSzif0po3jy6y2etZNZwCZUWmz7t0aHvFXj5joWJw54Oj5u/zAn9X45e41xsn0p2WiOdNKshr1xajbkeBRuaNqDbnUGQCxA/Ti9wBGSXAaVhDRHmnkkvKAS/OtaDe5pU7TA8IAdmHDphd8GyAxhIQL9GH+k="
7 changes: 4 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ npm t
# run unit tests in watch mode
npm run test:dev
# run unit integration tests
# run unit integration tests using sauce (this requires a valid SAUCE_ACCESS_KEY and SAUCE_USERNAME to be on the environment)
# feel free to omit this step; it will be run when you pull request your changes
npm run test:integration
```

This module uses [semantic release](https://github.com/semantic-release/semantic-release) to automate the publication of new changes. To allow this to happen, your commit message should follow the [angular.js conventions](https://docs.google.com/document/d/1QrDFcIiPjSLDn3EL15IJygNPiHORgU1_OOAqWjiDU5Y/edit). Put simply, prefix your commit message with `feat:`, `fix:`, or `fix` depending on the nature of the change e.g. `feat: add support for magic.js`, `fix: correct typo`, `fix update README`.
This module uses [semantic release](https://github.com/semantic-release/semantic-release) to automate the publication of new changes. To allow this to happen, your commit message should follow the [angular.js conventions](https://docs.google.com/document/d/1QrDFcIiPjSLDn3EL15IJygNPiHORgU1_OOAqWjiDU5Y/edit). Put simply, prefix your commit message with `feat:`, `fix:`, or `chore:` depending on the nature of the change e.g. `feat: add support for magic.js`, `fix: correct typo in error message`, `chore: fix update README`.

Please try to add test coverage for any new features.
Please add or update a test to cover your fix or feature.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"lint": "standard",
"test": "npm run lint && npm run test:unit && npm run test:integration",
"test:unit": "mocha --opts test/unit/mocha.opts",
"test:integration": "webdriver-manager update && npm run build && mocha --opts test/integration/mocha.opts --slow 30001 --timeout 30000 --reporter tap",
"test:integration": "npm run build && mocha --opts test/integration/mocha.opts --slow 30001 --timeout 30000 --reporter tap",
"test:dev": "mocha --watch --opts test/unit/mocha.opts",
"build": "babel -d dist src",
"prepublish": "npm run build",
Expand All @@ -38,7 +38,7 @@
"mocha": "^2.2.5",
"morgan": "^1.6.1",
"mversion": "^1.10.0",
"protractor": "^2.1.0",
"protractor": "^4.0.11",
"proxyquire": "^1.6.0",
"semantic-release": "^4.3.4",
"sinon": "^1.15.4",
Expand Down
13 changes: 8 additions & 5 deletions test/integration/support/protractor-config/always-fail.conf.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
'use strict';

var JOB_NAME = 'Flake';
var JOB_NUMBER = (process.env.TRAVIS_JOB_NUMBER || '')
var JOB_NAME = 'Flake' + JOB_NUMBER

exports.config = {
specs: [
Expand All @@ -9,15 +10,17 @@ exports.config = {
],

capabilities: {
browserName: process.platform === 'darwin' ? 'chrome' : 'firefox',
browserName: 'chrome',
name: JOB_NAME,
shardTestFiles: true,
maxInstances: 2
maxInstances: 2,
'tunnel-identifier': JOB_NUMBER
},

baseUrl: 'http://localhost:3000/',
sauceUser: process.env.SAUCE_USERNAME,
sauceKey: process.env.SAUCE_ACCESS_KEY,

directConnect: true,
baseUrl: 'http://localhost:3000/',

framework: 'jasmine',

Expand Down
13 changes: 8 additions & 5 deletions test/integration/support/protractor-config/sharded.conf.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
'use strict';

var JOB_NAME = 'Flake';
var JOB_NUMBER = (process.env.TRAVIS_JOB_NUMBER || '')
var JOB_NAME = 'Flake' + JOB_NUMBER

exports.config = {
specs: [
Expand All @@ -9,15 +10,17 @@ exports.config = {
],

capabilities: {
browserName: process.platform === 'darwin' ? 'chrome' : 'firefox',
browserName: 'chrome',
name: JOB_NAME,
shardTestFiles: true,
maxInstances: 2
maxInstances: 2,
'tunnel-identifier': JOB_NUMBER
},

baseUrl: 'http://localhost:3000/',
sauceUser: process.env.SAUCE_USERNAME,
sauceKey: process.env.SAUCE_ACCESS_KEY,

directConnect: true,
baseUrl: 'http://localhost:3000/',

framework: 'jasmine',

Expand Down
40 changes: 0 additions & 40 deletions test/integration/support/protractor-config/with-suite.conf.js

This file was deleted.

0 comments on commit 9cce406

Please sign in to comment.