karma.conf.js 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. // Karma configuration
  2. // Generated on Sat Oct 18 2014 17:38:05 GMT-0700 (PDT)
  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: ['mocha'],
  10. // list of files / patterns to load in the browser
  11. files: [
  12. 'build/graphlib.js',
  13. 'node_modules/chai/chai.js',
  14. 'test/bundle-test.js'
  15. ],
  16. // list of files to exclude
  17. exclude: [
  18. ],
  19. // preprocess matching files before serving them to the browser
  20. // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
  21. preprocessors: {
  22. },
  23. // test results reporter to use
  24. // possible values: 'dots', 'progress'
  25. // available reporters: https://npmjs.org/browse/keyword/karma-reporter
  26. reporters: ['progress'],
  27. // web server port
  28. port: 9876,
  29. // enable / disable colors in the output (reporters and logs)
  30. colors: true,
  31. // level of logging
  32. // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
  33. logLevel: config.LOG_INFO,
  34. // enable / disable watching file and executing tests whenever any file changes
  35. autoWatch: true,
  36. // start these browsers
  37. // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
  38. browsers: ['Chrome', 'Firefox', 'Safari'],
  39. // Continuous Integration mode
  40. // if true, Karma captures browsers, runs the tests and exits
  41. singleRun: false
  42. })
  43. }