Skip to content
This repository has been archived by the owner on Apr 15, 2019. It is now read-only.

Commit

Permalink
Set up sourcemaps in karma
Browse files Browse the repository at this point in the history
  • Loading branch information
slaweet committed Aug 25, 2017
1 parent 0bd0d09 commit 460e98a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions karma.conf.js
Expand Up @@ -17,6 +17,7 @@ module.exports = function (config) {
{ pattern: filePattern, included: false, served: false, watched: false },
],
preprocessors: {
'**/*.js': ['sourcemap'],
[fileRoot]: ['webpack'],
},
reporters: ['coverage', 'mocha'],
Expand Down
1 change: 1 addition & 0 deletions package.json
Expand Up @@ -91,6 +91,7 @@
"karma-jenkins-reporter": "0.0.2",
"karma-mocha": "=1.3.0",
"karma-mocha-reporter": "=2.2.3",
"karma-sourcemap-loader": "=0.3.7",
"karma-verbose-reporter": "=0.0.6",
"karma-webpack": "=2.0.3",
"mocha": "=3.2.0",
Expand Down
2 changes: 1 addition & 1 deletion webpack.config.js
Expand Up @@ -27,7 +27,7 @@ module.exports = (env) => {
path: path.resolve(__dirname, 'app', 'dist'),
filename: env.test ? 'bundle.js' : 'bundle.[name].js',
},
devtool: 'source-map',
devtool: env.test ? 'inline-source-map' : 'source-map',
devServer: {
contentBase: 'src',
inline: true,
Expand Down

0 comments on commit 460e98a

Please sign in to comment.