-
Notifications
You must be signed in to change notification settings - Fork 36
/
karma.conf.js
49 lines (41 loc) · 905 Bytes
/
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
var tsConfig = require('./tsconfig.json');
tsConfig.compilerOptions.target = 'es5';
module.exports = function(config){
var options = {
basePath: 'dist',
browsers: ['Chrome'],
frameworks: ['angular', 'mocha', 'browserify'],
reporters: ['mocha'],
angular: ['mocks'],
files: [
require.resolve('babel-core/browser-polyfill'),
'../node_modules/reflect-metadata/Reflect.js',
'lib/**/*.spec.js'
],
preprocessors: {
'lib/**/*.js': ['browserify']
},
browserify: {
watch: true,
noParse: [
// require.resolve('sinon-chai')
],
transform: [
['babelify', { stage: 0 }],
['aliasify', { aliases: {
'rxjs-es/Subject': 'rxjs/Subject'
}}]
]
},
customLaunchers: {
Chrome_travis_ci: {
base: 'Chrome',
flags: ['--no-sandbox']
}
}
};
if(process.env.TRAVIS){
options.browsers = ['Chrome_travis_ci'];
}
config.set(options);
};