Last active
August 29, 2015 13:57
-
-
Save kevinohara80/9898305 to your computer and use it in GitHub Desktop.
gulpfile.js
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'); | |
var jshint = require('gulp-jshint'); | |
var stylish = require('jshint-stylish'); | |
var mocha = require('gulp-mocha'); | |
gulp.task('lint', function(){ | |
return gulp.src(['./*.js', './lib/**/*.js', './models/**/*.js', './routes/**/*.js']) | |
.pipe(jshint('.jshintrc')) | |
.pipe(jshint.reporter('jshint-stylish')); | |
}); | |
gulp.task('mocha', function(){ | |
return gulp.src(['./test/*.js']) | |
.pipe(mocha({ | |
reporter: 'spec', | |
globals: { | |
should: require('should') | |
} | |
})); | |
}); | |
gulp.task('test', ['lint', 'mocha']); | |
gulp.task('default', ['test']); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment