Skip to content

Commit

Permalink
Rename remaining legacy tests options to testPath
Browse files Browse the repository at this point in the history
  • Loading branch information
philipwalton committed Oct 22, 2016
1 parent 38053ad commit 933bd96
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
7 changes: 4 additions & 3 deletions README.md
Expand Up @@ -47,14 +47,14 @@ Options:
This defaults to the SAUCE_USERNAME environment variable.
-k, --key Your Sauce Labs access key.
This defaults to the SAUCE_ACCESS_KEY environmentvariable.
This defaults to the SAUCE_ACCESS_KEY environment variable.
-P, --platforms An array of platform/browser/version capabilities.
This should be a JSON array of arrays, e.g.: '[["Windows
10", "chrome", "latest"], ["OS X 10.11", "safari", "9"]]'.
See https://goo.gl/tPnZDO for details.
-t, --tests The URL path to the file that loads the tests.
-t, --test-path The URL path to the file that loads the tests.
Defaults to "/test/"
-p, --port The port to run the local server on.
Expand All @@ -74,6 +74,7 @@ Options:
-s, --service Service used to create the tunnel to localhost.
This can be "localtunnel", "ngrok", or "sauce-connect".
Defaults to "localtunnel".
See package details here:
https://www.npmjs.com/package/localtunnel
https://www.npmjs.com/package/ngrok
https://www.npmjs.com/package/sauce-connect-launcher
Expand Down Expand Up @@ -107,8 +108,8 @@ If you're testing an npm package, you can skip the external configuration file a
},
// ...
"easySauce": {
"tests": "/tests/all-tests.html",
"port": "8080",
"testPath": "/test/runner.html",
"platforms": [
[
"Windows 10",
Expand Down
4 changes: 2 additions & 2 deletions lib/easy-sauce.js
Expand Up @@ -18,7 +18,7 @@ class EasySauce {
username: null,
key: null,
port: 8080,
tests: '/test/',
testPath: '/test/',
platforms: null,
build: Math.floor(Date.now() / 1000),
name: 'JS Unit Tests',
Expand Down Expand Up @@ -95,7 +95,7 @@ class EasySauce {

startJobs() {
return new Promise((resolve, reject) => {
let url = this.service.baseUrl + this.opts.tests;
let url = this.service.baseUrl + this.opts.testPath;
let opts = {
url: `${API_PATH}/${this.opts.username}/js-tests`,
json: true,
Expand Down
4 changes: 2 additions & 2 deletions test/easy-sauce-test.js
Expand Up @@ -48,7 +48,7 @@ describe('EasySauce', () => {
username: 'me',
key: 'secret',
port: 1979,
tests: '/test/',
testPath: '/test/',
platforms: [
['Windows 10', 'chrome', 'latest'],
['OS X 10.11', 'firefox', 'latest'],
Expand Down Expand Up @@ -344,7 +344,7 @@ describe('EasySauce', () => {
assert(es.logger.emit.calledOnce);
assert(es.logger.emit.calledWith(
'message',
messages('JOBS_STARTED', es.service.baseUrl + es.opts.tests)));
messages('JOBS_STARTED', es.service.baseUrl + es.opts.testPath)));

es.logger.emit.restore();
done();
Expand Down

0 comments on commit 933bd96

Please sign in to comment.