From a1cce240105bf90c30a84e882848a7875b801d4f Mon Sep 17 00:00:00 2001 From: Blade Barringer Date: Sat, 6 Jun 2015 12:14:28 -0500 Subject: [PATCH 1/2] Make test groups depend on specific test:prepare tasks --- tasks/gulp-tests.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tasks/gulp-tests.js b/tasks/gulp-tests.js index ab0007ef17..5aba3550dd 100644 --- a/tasks/gulp-tests.js +++ b/tasks/gulp-tests.js @@ -37,7 +37,7 @@ gulp.task('test:prepare', [ 'test:prepare:webdriver' ]); -gulp.task('test:common', ['test:prepare'], (cb) => { +gulp.task('test:common', ['test:prepare:build'], (cb) => { let runner = exec( testBin('mocha test/common'), cb ); @@ -45,14 +45,14 @@ gulp.task('test:common', ['test:prepare'], (cb) => { }); -gulp.task('test:api', ['test:prepare'], (cb) => { +gulp.task('test:api', ['test:prepare:mongo'], (cb) => { let runner = exec( testBin('mocha test/api'), cb ); pipe(runner); }); -gulp.task('test:karma', ['test:prepare'], (cb) => { +gulp.task('test:karma', ['test:prepare:build'], (cb) => { let runner = exec( testBin('karma start --single-run'), cb ); From ed421ebcc5b4bc771d4bc15eb525cfe06505e164 Mon Sep 17 00:00:00 2001 From: Blade Barringer Date: Sat, 6 Jun 2015 12:15:17 -0500 Subject: [PATCH 2/2] Set npm test to call gulp test --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 9b4832f5f0..f88dd2fbf6 100644 --- a/package.json +++ b/package.json @@ -78,7 +78,7 @@ "node": "0.10.x" }, "scripts": { - "test": "./node_modules/.bin/gulp", + "test": "./node_modules/.bin/gulp test", "start": "grunt run:dev", "postinstall": "./node_modules/bower/bin/bower --config.interactive=false install -f; ./node_modules/.bin/grunt;", "coverage": "COVERAGE=true mocha --require register-handlers.js --reporter html-cov > coverage.html; open coverage.html"