diff options
Diffstat (limited to 'config')
-rw-r--r-- | config/karma.config.js | 7 | ||||
-rw-r--r-- | config/webpack.config.js | 2 |
2 files changed, 9 insertions, 0 deletions
diff --git a/config/karma.config.js b/config/karma.config.js index 44229e2ee88..a1fbeab1f46 100644 --- a/config/karma.config.js +++ b/config/karma.config.js @@ -15,6 +15,13 @@ module.exports = function(config) { preprocessors: { 'spec/javascripts/**/*.js?(.es6)': ['webpack', 'sourcemap'], }, + reporters: ['progress', 'coverage-istanbul'], + coverageIstanbulReporter: { + reports: ['html', 'text-summary'], + dir: 'coverage-javascript/', + subdir: '.', + fixWebpackSourcePaths: true + }, webpack: webpackConfig, webpackMiddleware: { stats: 'errors-only' }, }); diff --git a/config/webpack.config.js b/config/webpack.config.js index 2ac779c8511..e63775e43ce 100644 --- a/config/webpack.config.js +++ b/config/webpack.config.js @@ -54,6 +54,7 @@ var config = { exclude: /(node_modules|vendor\/assets)/, loader: 'babel-loader', options: { + plugins: IS_PRODUCTION ? [] : ['istanbul'], presets: [ ["es2015", {"modules": false}], 'stage-2' @@ -82,6 +83,7 @@ var config = { new CompressionPlugin({ asset: '[path].gz[query]', }), + new webpack.IgnorePlugin(/moment/, /pikaday/), ], resolve: { |