You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

karma.conf.js 1.8KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. // Karma configuration
  2. // Generated on Wed Dec 07 2016 14:40:28 GMT-0800 (PST)
  3. module.exports = function(config) {
  4. config.set({
  5. // base path that will be used to resolve all patterns (eg. files, exclude)
  6. basePath: '',
  7. // frameworks to use
  8. // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
  9. frameworks: [ 'jasmine' ],
  10. // list of files / patterns to load in the browser
  11. files: [
  12. './index.js',
  13. './modules/**/*.spec.js'
  14. ],
  15. // list of files to exclude
  16. exclude: [
  17. ],
  18. // preprocess matching files before serving them to the browser
  19. // available preprocessors:
  20. // https://npmjs.org/browse/keyword/karma-preprocessor
  21. preprocessors: {
  22. './index.js': [ 'webpack' ],
  23. './**/*.spec.js': [ 'webpack' ]
  24. },
  25. // test results reporter to use
  26. // possible values: 'dots', 'progress'
  27. // available reporters: https://npmjs.org/browse/keyword/karma-reporter
  28. reporters: [ 'progress' ],
  29. // web server port
  30. port: 9876,
  31. // enable / disable colors in the output (reporters and logs)
  32. colors: true,
  33. // level of logging
  34. // possible values: config.LOG_DISABLE || config.LOG_ERROR ||
  35. // config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
  36. logLevel: config.LOG_INFO,
  37. // enable / disable watching file and executing tests whenever
  38. // any file changes
  39. autoWatch: false,
  40. // start these browsers
  41. // available browser launchers:
  42. // https://npmjs.org/browse/keyword/karma-launcher
  43. browsers: [ 'Chrome' ],
  44. // Continuous Integration mode
  45. // if true, Karma captures browsers, runs the tests and exits
  46. singleRun: false,
  47. webpack: require('./webpack.config.js')
  48. });
  49. };