converter/config/karma.conf.js
Manuel Friedli 77a79bf588 Added a first simple test.
That serves as a proof-of-concept and as a template for future tests.
It's a start!
2017-03-15 02:22:24 +01:00

44 lines
1,003 B
JavaScript

var webpackConfig = require('./webpack.test');
module.exports = function (config) {
var _config = {
basePath: '',
frameworks: ['jasmine'],
files: [
{
pattern: './config/karma-test-shim.js',
watched: false
}
],
preprocessors: {
'./config/karma-test-shim.js': ['webpack', 'sourcemap']
},
webpack: webpackConfig,
webpackMiddleware: {
stats: 'errors-only'
},
webpackServer: {
noInfo: true
},
reporters: ['kjhtml'],
port: 9876,
colors: true,
logLevel: config.LOG_INFO,
autoWatch: false,
browsers: ['PhantomJS'],
singleRun: true,
phantomjsLauncher: {
// Have phantomjs exit if a ResourceError is encountered (useful if karma exits without killing phantom)
exitOnResourceError: true
}
};
config.set(_config);
};