forked from amplitude/Amplitude-JavaScript
-
Notifications
You must be signed in to change notification settings - Fork 0
/
karma.conf.js
55 lines (54 loc) · 1.48 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
51
52
53
54
55
module.exports = function(config) {
const customLaunchers = {
sauce_ie_8: {
base: 'SauceLabs',
browserName: 'internet explorer',
platform: 'Windows 7',
version: '8'
},
sauce_ie9: {
base: 'SauceLabs',
browserName: 'internet explorer',
platform: 'Windows 7',
version: '9.0'
},
sauce_edge: {
base: 'SauceLabs',
browserName: 'MicrosoftEdge',
platform: 'Windows 10',
},
sauce_chrome_windows: {
base: 'SauceLabs',
browserName: 'chrome',
platform: 'Windows 10',
},
sauce_safari_sierra: {
base: 'SauceLabs',
browserName: 'safari',
platform: 'macOS 10.12',
},
};
config.set({
sauceLabs: {
testName: 'Amplitude JavaScript SDK',
},
preprocessors: {
'**/*.js': ['sourcemap']
},
frameworks: ['mocha', 'chai'],
// files: ['amplitude-snippet.min.js', 'build/snippet-tests.js', 'build/tests.js'], @TODO: Fix flaky build/snippet-tests.js and re-enable
files: ['amplitude-snippet.min.js', 'build/tests.js'],
reporters: ['mocha', 'saucelabs'],
port: 9876, // karma web server port
colors: true,
logLevel: config.LOG_INFO,
customLaunchers,
captureTimeout: 120000,
browsers: ['ChromeHeadless'],
// browsers: ['sauce_chrome_windows', 'sauce_edge', 'sauce_safari_sierra'],
autoWatch: false,
singleRun: true,
// singleRun: false, // Karma captures browsers, runs the tests and exits
concurrency: 4,
})
}