forked from Moharu/beetles
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Gruntfile.js
29 lines (29 loc) · 983 Bytes
/
Gruntfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
module.exports = function(grunt){
var config = {
mochaTest: {
progress: {
options: {
reporter: 'progress'
},
src: ['test/**/*.js']
}
},
watch: {
src: {
files: ['src/**/*.js', 'test/**/*.js'],
tasks: ['test']
}
},
exec: {
html_coverage: './node_modules/mocha/bin/mocha test -r blanket --reporter html-cov --recursive > coverage.html',
coverage: './node_modules/mocha/bin/mocha test -r blanket --reporter mocha-cov-reporter --recursive'
}
}
grunt.initConfig(config)
require('load-grunt-tasks')(grunt)
grunt.registerTask('default', 'Watch', function(){
grunt.task.run('watch')
})
grunt.registerTask('test', ['mochaTest:progress'])
// grunt.registerTask('test', ['mochaTest:progress', 'exec:coverage', 'exec:html_coverage'])
}