-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathkarma.conf.js
42 lines (39 loc) · 1.02 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
'use strict';
module.exports = function (config) {
// Chai first so it doesn't know about almond and AMD itself
var files = [require.resolve('chai/chai')];
// Bit nasty...
if (process.env.AMD) {
console.log('Testing AMD');
// Almond before the main module
files.push(require.resolve('almond'));
// Main module
files.push(require('./main-path'));
// AMD test 'adapter' before tests
files.push('test-amd-bootstrap.js');
} else {
files.push(require('./main-path'));
}
files.push('test/*-tests.js');
config.set({
basePath: '',
frameworks: ['mocha'],
files: files,
exclude: [],
preprocessors: {},
reporters: ['progress'],
port: 9876,
colors: true,
logLevel: config.LOG_INFO,
autoWatch: true,
customLaunchers: {
ChromeHeadlessNoSandbox: {
base: 'ChromeHeadless',
flags: ['--no-sandbox'] // Rquired for non-root
}
},
browsers: ['ChromeHeadlessNoSandbox', 'Firefox'],
singleRun: true,
concurrency: Infinity
});
};