diff --git a/gulpfile.js b/gulpfile.js index 845f2e31f2e0..12c23bd5bd47 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -31,6 +31,7 @@ var rename = require('gulp-rename'); var replace = require('gulp-replace'); var source = require('vinyl-source-stream'); var sourcemaps = require('gulp-sourcemaps'); +var touch = require('touch') var uglify = require('gulp-uglify'); var util = require('gulp-util'); var watchify = require('watchify'); @@ -443,6 +444,10 @@ function compileJs(srcDir, srcFilename, destDir, options) { bundler.on('update', function() { console.log('-> bundling ' + srcDir + '...'); rebundle(); + // Touch file in unit test set. This triggers rebundling of tests because + // karma only considers changes to tests files themselves re-bundle + // worthy. + touch('test/_init_tests.js'); }); } diff --git a/package.json b/package.json index b22a2df7ae1e..915c750f2525 100644 --- a/package.json +++ b/package.json @@ -41,7 +41,7 @@ "finalhandler": "0.4.0", "fs-extra": "0.26.4", "gulp": "3.9.0", - "gulp-closure-compiler": "^0.4.0", + "gulp-closure-compiler": "0.4.0", "gulp-eslint": "1.1.0", "gulp-exec": "2.1.2", "gulp-file": "0.2.0", @@ -72,7 +72,7 @@ "karma-sauce-launcher": "0.2.14", "karma-sinon-chai": "1.0.0", "lazypipe": "1.0.1", - "lolex": "^1.4.0", + "lolex": "1.4.0", "minimist": "1.2.0", "mocha": "2.3.3", "path": "0.12.7", @@ -85,6 +85,7 @@ "sinon-chai": "2.8.0", "text-table": "0.2.0", "through2": "2.0.0", + "touch": "1.0.0", "vinyl-buffer": "1.0.0", "vinyl-source-stream": "1.1.0", "watchify": "3.6.0"