webpack-cov.conf.js 502 B

1234567891011121314151617181920212223
  1. var path = require('path');
  2. module.exports = {
  3. entry: './test/build/index.js',
  4. output: {
  5. filename: './test/build/coverage.js'
  6. },
  7. bail: true,
  8. module: {
  9. loaders: [
  10. { test: /\.json$/, loader: 'json-loader' },
  11. { test: /\.css$/, loader: 'style-loader!css-loader' },
  12. ],
  13. preLoaders: [
  14. // instrument only testing sources with Istanbul
  15. {
  16. test: /\.js$/,
  17. include: path.resolve('lib/'),
  18. loader: 'istanbul-instrumenter'
  19. }
  20. ]
  21. }
  22. }