-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathkarma.base.js
64 lines (63 loc) · 1.5 KB
/
karma.base.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
const chromeFlags = [
'--use-fake-device-for-media-stream',
'--use-fake-ui-for-media-stream',
'--use-file-for-fake-audio-capture=./assets/1.wav',
];
const firefoxFlags = {
'media.navigator.permission.disabled': true,
'media.navigator.streams.fake': true,
'network.http.max-persistent-connections-per-server': 10000,
};
module.exports = {
basePath: '',
frameworks: ['jasmine', 'karma-typescript'],
exclude: [],
reporters: ['progress', 'coverage'],
port: 9876,
colors: true,
autoWatch: true,
customLaunchers: {
chrome_with_fake_device: {
base: 'Chrome',
flags: chromeFlags,
},
chrome_headless_with_fake_device: {
base: 'ChromeHeadless',
flags: chromeFlags,
},
safari: {
base: 'Safari',
},
FirefoxAutoAllowGUM: {
base: 'Firefox',
prefs: firefoxFlags,
},
FirefoxHeadlessAutoAllowGUM: {
base: 'FirefoxHeadless',
prefs: firefoxFlags,
},
},
singleRun: false,
concurrency: Infinity,
karmaTypescriptConfig: {
compilerOptions: {
baseUrl: '.',
module: 'commonjs',
target: 'ES2020',
lib: ['DOM', 'ES2020'],
sourceMap: true,
declaration: true,
declarationMap: true,
noEmitOnError: true,
skipLibCheck: true,
esModuleInterop: true,
strict: true,
},
exclude: ['node_modules', 'example', 'examples', 'debug', 'typedoc', 'doc'],
bundlerOptions: {
transforms: [
require('karma-typescript-es6-transform')()
]
},
},
};