-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathGruntfile.js
68 lines (57 loc) · 1.21 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
module.exports = function ( grunt ) {
require( 'load-grunt-tasks' )( grunt );
// Project configuration
grunt.initConfig( {
// Configure ESLint task
eslint: {
all: [
'**/*.js',
'!node_modules/**'
]
},
// Configure JSONLint task
jsonlint: {
all: [
'**/*.json',
'!node_modules/**'
]
},
// Configure run task
run: {
index: {
args: [ 'test/main_page.js' ]
},
webdriverio: {
args: [ 'webdriverio/stack/webdriverio.js' ]
}
},
// Configure Mocha task
mochaTest: {
test: {
options: {
reporter: 'spec',
timeout: 100000
},
src: [ 'webdriverjs/**/*.js' ]
}
},
// Configure WebdriverIO task
webdriver: {
test: {
configFile: './wdio.conf.js'
}
},
// Configure Nightwatch task
nightwatch: {
options: {
// nightwatch settings
// jscs:disable requireCamelCaseOrUpperCaseIdentifiers
src_folders: [ 'nightwatch' ], // eslint-disable-line camelcase
output_folder: 'report' // eslint-disable-line camelcase
// jscs:enable requireCamelCaseOrUpperCaseIdentifiers
}
}
} );
// Default tasks
grunt.registerTask( 'default', [ 'eslint', 'jsonlint', 'run', 'mochaTest', 'nightwatch', 'webdriver' ] );
};