Skip to content

Instantly share code, notes, and snippets.

@dbernar1
Created November 11, 2014 14:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dbernar1/7510e801aa52c896aa15 to your computer and use it in GitHub Desktop.
Save dbernar1/7510e801aa52c896aa15 to your computer and use it in GitHub Desktop.
Gulpfile which converts CoffeeScript into JavaScript before running unit tests through Karma
var coffee = require('gulp-coffee'),
karma = require('karma').server;
gulp.task('compile-tests-coffee', functoin() {
return gulp.src('./test/unit/**/*.coffee')
.pipe(coffee({bare: true}))
.pipe(gulp.dest('test/unit'));
});
gulp.task('unit-test', ['compile-tests-coffee'], function () {
karma.start({
configFile: __dirname + '/test/karma.config.js',
autoWatch: true
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment