-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathGruntfile.js
46 lines (39 loc) · 1 KB
/
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*
* helper-lib
* http://github.com/assemble/helper-lib
*/
module.exports = function(grunt) {
'use strict';
// Project configuration.
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
// Configuration to be run (and then tested).
// Run mocha tests.
simplemocha: {
options: {
globals:['should'],
timeout: 3000,
ignoreLeaks: false,
ui: 'bdd',
reporter: 'tap'
},
all: {src: ['test/**/*.js'] }
},
jshint: {
options: {
jshintrc: '.jshintrc'
},
all: ['if.js', 'src/**/*.js', 'test/**/*.js']
},
// Clean test files before building or re-testing.
clean: {
}
});
// These plugins provide necessary tasks.
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-simple-mocha');
// By default, build templates using helpers and run all tests.
grunt.registerTask('validate', ['jshint:all']);
grunt.registerTask('test', ['simplemocha']);
};