Skip to content

Commit

Permalink
Accept args for test specs to run
Browse files Browse the repository at this point in the history
  • Loading branch information
jamespamplin committed Jun 26, 2015
1 parent 5b0f6ca commit 9833ed3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion run-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export TEST_SERVER_PORT=${TEST_SERVER_PORT:=8880}

./node_modules/.bin/http-server -p $TEST_SERVER_PORT --silent &
PID=$!
node test/runner
node test/runner $@
TEST_RUNNER_EXIT=$?
kill $PID

Expand Down
4 changes: 3 additions & 1 deletion test/runner.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,15 @@ var testEnvironment = require('scribe-test-harness/environment');

var mocha = new Mocha();

var specs = process.argv[2] || (__dirname + '/**/*.spec.js');

/**
* Wait for the connection to Sauce Labs to finish.
*/
mocha.timeout(15 * 1000);
mocha.reporter('spec');

testEnvironment.loadSpecifications(__dirname + '/**/*.spec.js', mocha)
testEnvironment.loadSpecifications(specs, mocha)
.then(function(mocha) {
createRunner(mocha);
});

0 comments on commit 9833ed3

Please sign in to comment.