forked from noam1987/react-here-maps
-
Notifications
You must be signed in to change notification settings - Fork 0
/
karma.conf.js
71 lines (62 loc) · 1.81 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
/**
* Please see Karma config file reference for better understanding:
* http://karma-runner.github.io/latest/config/configuration-file.html
*/
module.exports = function(config) {
config.set({
/**
* This path will be used for resolving.
*/
basePath: '',
/**
* List of test frameworks we will use. Most of them are provided by separate packages (adapters).
* You can find them on npmjs.org: https://npmjs.org/browse/keyword/karma-adapter
*/
frameworks: ['mocha', 'chai', 'sinon', 'source-map-support'],
/**
* Entry point / test environment builder is also written in TypeScript.
*/
files: ['./test/test.scss', './test/main.tests.ts'],
/**
* Transform files before loading them.
*/
preprocessors: {
'./test/test.scss': ['webpack'],
'./test/main.tests.ts': ['webpack'],
},
webpack: require('./webpack/webpack.test.js'),
/**
* Make dev server silent.
*/
webpackServer: { noInfo: true },
/**
* A lot of plugins are available for test results reporting.
* You can find them here: https://npmjs.org/browse/keyword/karma-reporter
*/
reporters: ['mocha', 'coverage'],
/**
* This JSON file is "intermediate", in post-test script we use remap-istanbul to map back to TypeScript
* and then generate coverage report.
*/
coverageReporter: {
dir: 'coverage',
reporters: [
{
type: 'json',
subdir: '.',
file: 'coverage.json'
}
]
},
/**
* Only Phantom is used in this example.
* You can find more browser launchers here: https://npmjs.org/browse/keyword/karma-launcher
*/
browsers: ['PhantomJS'],
/**
* This is CI mode: run once and exit.
*/
autoWatch: true,
singleRun: true
});
};