-
Notifications
You must be signed in to change notification settings - Fork 0
/
karma.conf.js
50 lines (49 loc) · 1.07 KB
/
karma.conf.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
// karma.conf.js
module.exports = function(config) {
config.set({
//logLevel: 'debug',
//browsers: ['Chrome'],
browsers: ['PhantomJS'],
// you can define custom flags
customLaunchers: {
Chrome_without_security: {
base: 'Chrome',
flags: ['--disable-web-security']
}
},
frameworks: ['mocha', 'sinon-chai', 'riot'],
plugins: [
'karma-mocha',
'karma-sinon-chai',
'karma-mocha-reporter',
'karma-phantomjs-launcher',
//'karma-chrome-launcher',
'karma-riot',
'karma-babel-preprocessor'
],
files: [
//'node_modules/expect.js/index.js',
'node_modules/chai/chai.js',
//'tag/*.tag',
//'test/**/*.js'
'js/game.js',
'test/game.js'
],
preprocessors: {
'**/*.tag': ['riot'],
'test/game.js': ['babel'],
'js/game.js': ['babel']
},
reporters: ['mocha'],
riotPreprocessor: {
options: {
type: 'babel'
}
},
babelPreprocessor: {
options: {
"presets": ["es2015"]
}
}
})
};