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.9KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  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,
  6. // exclude)
  7. basePath: '',
  8. // frameworks to use
  9. // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
  10. frameworks: [ 'jasmine' ],
  11. // list of files / patterns to load in the browser
  12. files: [
  13. './index.js',
  14. './modules/**/*.spec.js'
  15. ],
  16. // list of files to exclude
  17. exclude: [
  18. ],
  19. // preprocess matching files before serving them to the browser
  20. // available preprocessors:
  21. // https://npmjs.org/browse/keyword/karma-preprocessor
  22. preprocessors: {
  23. './index.js': [ 'webpack' ],
  24. './**/*.spec.js': [ 'webpack' ]
  25. },
  26. // test results reporter to use
  27. // possible values: 'dots', 'progress'
  28. // available reporters: https://npmjs.org/browse/keyword/karma-reporter
  29. reporters: [ 'progress' ],
  30. // web server port
  31. port: 9876,
  32. // enable / disable colors in the output (reporters and logs)
  33. colors: true,
  34. // level of logging
  35. // possible values: config.LOG_DISABLE || config.LOG_ERROR ||
  36. // config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
  37. logLevel: config.LOG_INFO,
  38. // enable / disable watching file and executing tests whenever
  39. // any file changes
  40. autoWatch: false,
  41. // start these browsers
  42. // available browser launchers:
  43. // https://npmjs.org/browse/keyword/karma-launcher
  44. browsers: [ 'Chrome' ],
  45. // Continuous Integration mode
  46. // if true, Karma captures browsers, runs the tests and exits
  47. singleRun: false,
  48. webpack: require('./webpack.config.js')
  49. });
  50. };