Passed
Push — master ( c74f2d...beff77 )
by Rafael
01:08
created

karma.config.js   A

Complexity

Total Complexity 1
Complexity/F 1

Size

Lines of Code 43
Function Count 1

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
nc 1
dl 0
loc 43
rs 10
noi 1
cc 0
wmc 1
mnd 0
bc 1
fnc 1
bpm 1
cpm 1

1 Function

Rating   Name   Duplication   Size   Complexity  
B module.exports 0 40 1
1
// Karma configuration
2
const path = require( 'path' );
3
const src = path.resolve( __dirname, '..', 'src' );
0 ignored issues
show
Unused Code introduced by
The constant src seems to be never used. Consider removing it.
Loading history...
4
5
module.exports = function( config ) {
6
	config.set( {
7
		frameworks: [ 'jasmine', 'es6-shim' ],
8
		reporters: [ 'spec' ],
9
		browsers: [ 'PhantomJS' ],
10
		colors: true,
11
12
		// ... normal karma configuration
13
		files: [
14
			'node_modules/babel-polyfill/dist/polyfill.js',
15
			require.resolve( 'jquery' ),
16
			'https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.8.3/underscore-min.js',
17
			'https://code.jquery.com/ui/1.12.1/jquery-ui.min.js',
18
			'node_modules/Iris/dist/iris.min.js',
19
20
			// All files ending in "_test"
21
			// { pattern: 'test/*_test.js', watched: false }
22
23
			{ pattern: 'test/**/*_test.js', watched: false }
24
25
			// Each file acts as entry point for the webpack configuration
26
		],
27
28
		preprocessors: {
29
30
			// Add webpack as preprocessor
31
			'test/*_test.js': [ 'webpack' ],
32
			'test/**/*_test.js': [ 'webpack' ]
33
		},
34
35
		webpack: require( './config/webpack.test.js' ),
36
37
		webpackMiddleware: {
38
39
			// Webpack-dev-middleware configuration
40
			// i. e.
41
			stats: 'errors-only'
42
		}
43
	} );
44
};
45