forked from fayriot/just-lightbox
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathkarma.conf.debug.js
57 lines (57 loc) · 1.98 KB
/
karma.conf.debug.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
const path = require('path');
module.exports = function (config) {
config.set({
plugins: [
require('karma-jasmine'),
require('karma-chrome-launcher'),
require('karma-jasmine'),
require('karma-sourcemap-loader'),
require('karma-spec-reporter'),
require('karma-webpack'),
],
browsers: ['Chrome'],
colors: true,
files: [path.join(process.cwd(), 'karma.entry.js')],
frameworks: ['jasmine'],
preprocessors: {
'karma.entry.js': ['webpack', 'sourcemap'],
},
singleRun: false,
webpack: {
devtool: 'inline-source-map',
mode: 'development',
module: {
rules: [
{test: /\.ts$/, use: ['ts-loader', 'angular2-template-loader']},
{test: /\.html$/, use: ['raw-loader']},
{test: /\.less$/, use: ['css-to-string-loader', 'css-loader', 'less-loader']},
{
exclude: [
path.resolve(__dirname, 'node_modules/@angular'),
path.resolve(__dirname, 'node_modules/rxjs'),
],
include: [path.resolve(__dirname, 'src')],
loader: 'istanbul-instrumenter-loader',
test: /\.ts$/,
enforce: 'post',
options: {
esModules: true,
},
},
],
},
resolve: {
extensions: ['.ts', '.tsx', '.json', '.js', '.html'],
modules: [
'node_modules',
path.resolve(__dirname, 'src'),
path.resolve(__dirname, 'tests'),
],
},
},
webpackServer: {
noInfo: true,
noLog: true,
},
});
};