forked from concur/concur-platform-sdk-js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGruntfile.js
44 lines (42 loc) · 1.25 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
module.exports = function(grunt){
// helper to automatically call grunt.loadNpmTasks('foo') for all package.json dependencies matching the pattern grunt-*
require('load-grunt-tasks')(grunt);
grunt.initConfig({
// plugin configuration details here
jshint: {
all: {
options: {
expr: true
},
src: ['Gruntfile.js', 'lib/**/*.js', 'test/**/*.js']
}
},
env: {
dev: {
APPLICATION_NAME: 'node-utils',
NODE_ENV: 'test'
}
},
mochaTest: {
test: {
options: {
reporter: 'spec',
ui: 'bdd',
captureFile: 'results.txt', // Optionally capture the reporter output to a file
quiet: false // Optionally suppress output to standard out (defaults to false)
},
src: ['test/*.js']
},
'ci-shippable': {
options: {
reporter: 'xunit',
captureFile: 'shippable/testresults/result.xml' // Optionally capture the reporter output to a file
},
src: ['test/*.js']
}
}
});
// register tasks
grunt.registerTask('default', ['npm-install', 'jshint', 'env:dev', 'mochaTest:test']);
grunt.registerTask('ci-shippable', ['jshint', 'env:dev', 'mochaTest:ci-shippable']);
};