-
Notifications
You must be signed in to change notification settings - Fork 0
/
Gruntfile.js
50 lines (44 loc) · 1.09 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
47
48
49
50
var exec = require('child_process').exec,
fs = require('fs'),
path = require('path');
const BIN = './node_modules/.bin/';
if (!process.env.NODE_ENV) {
process.env.NODE_ENV = 'development';
}
module.exports = function(grunt) {
// Project configuration.
grunt.initConfig({
appcJs: {
options: {
force: false
},
src: ['index.js', 'lib/**/*.js']
},
mochaTest: {
options: {
timeout: 40000,
reporter: 'spec',
bail: true,
ignoreLeaks: false,
globals: ['_key', 'requestSSLInitializing', 'requestSSLInsideHook', 'requestSSLInitialized']
},
src: ['test/appc_platform_sdk_tests.js']
},
kahvesi: {
src: ['test/appc_platform_sdk_tests.js']
},
appcCoverage: {
default_options: {
src: 'coverage/lcov.info',
force: true
}
}
});
// Load grunt plugins for modules
grunt.loadNpmTasks('grunt-appc-js');
grunt.loadNpmTasks('grunt-mocha-test');
grunt.loadNpmTasks('grunt-kahvesi');
grunt.loadNpmTasks('grunt-appc-coverage');
grunt.registerTask('cover', ['kahvesi', 'appcCoverage']);
grunt.registerTask('default', ['appcJs', 'mochaTest']);
};