-
Notifications
You must be signed in to change notification settings - Fork 5
/
no-soy.js
47 lines (39 loc) · 1.1 KB
/
no-soy.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
'use strict';
var babelPresetMetal = require('babel-preset-metal');
var karmaBabelPreprocessor = require('karma-babel-preprocessor');
var karmaChai = require('karma-chai');
var karmaChromeLauncher = require('karma-chrome-launcher');
var karmaCommonJs = require('karma-commonjs');
var karmaMocha = require('karma-mocha');
var karmaSinon = require('karma-sinon');
var karmaSourceMapSupport = require('karma-source-map-support');
var babelOptions = {
presets: [babelPresetMetal],
sourceMap: 'both'
};
module.exports = function (config) {
config.set({
plugins: [
karmaBabelPreprocessor,
karmaChai,
karmaChromeLauncher,
karmaCommonJs,
karmaMocha,
karmaSourceMapSupport,
karmaSinon
],
frameworks: ['mocha', 'chai', 'sinon', 'source-map-support', 'commonjs'],
files: [
'node_modules/metal*/src/**/*.js',
'src/**/*.js',
'test/**/*.js'
],
preprocessors: {
'src/**/*.js': ['babel', 'commonjs'],
'node_modules/metal*/src/**/*.js': ['babel', 'commonjs'],
'test/**/*.js': ['babel', 'commonjs']
},
browsers: ['Chrome'],
babelPreprocessor: {options: babelOptions}
});
};