Created
April 1, 2014 15:01
-
-
Save iamdustan/9915940 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var gulp = require('gulp'); | |
module.exports = function(config) { | |
var src = config.paths.test | |
return function() { | |
var browserify = require('gulp-browserify'); | |
var karma = require('gulp-karma'); | |
var es6ify = require('es6ify'); | |
return gulp.src(src) | |
.pipe(browserify({ | |
debug: true, | |
add: [ es6ify.runtime ], | |
transform: ['reactify', 'es6ify'] | |
})) | |
.pipe(karma({ | |
configFile: 'karma.conf.js', | |
action: 'run' | |
})) | |
.on('error', function(err) { | |
// Make sure failed tests cause gulp to exit non-zero | |
throw err; | |
}); | |
}; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment