karma.conf.js 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. // Karma configuration
  2. // Generated on Fri May 22 2015 12:59:26 GMT-0400 (EDT)
  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', 'requirejs'],
  10. // list of files / patterns to load in the browser
  11. files: [
  12. 'vendors/jquery/jquery-1.11.0.min.js',
  13. 'vendors/jquery/jquery-migrate-1.2.1.min.js',
  14. 'vendors/sprintf.js',
  15. 'js/lib/elgglib.js',
  16. 'js/lib/hooks.js',
  17. 'js/classes/*.js',
  18. 'js/lib/*.js',
  19. {pattern:'js/tests/*Test.js',included: false},
  20. {pattern:'views/default/js/**/*.js',included:false},
  21. 'js/tests/requirejs.config.js',
  22. ],
  23. // list of files to exclude
  24. exclude: [
  25. ],
  26. // preprocess matching files before serving them to the browser
  27. // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
  28. preprocessors: {
  29. },
  30. // test results reporter to use
  31. // possible values: 'dots', 'progress'
  32. // available reporters: https://npmjs.org/browse/keyword/karma-reporter
  33. reporters: ['progress'],
  34. // web server port
  35. port: 9876,
  36. // enable / disable colors in the output (reporters and logs)
  37. colors: true,
  38. // level of logging
  39. // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
  40. logLevel: config.LOG_INFO,
  41. // enable / disable watching file and executing tests whenever any file changes
  42. autoWatch: false,
  43. // start these browsers
  44. // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
  45. browsers: ['PhantomJS'],
  46. // Continuous Integration mode
  47. // if true, Karma captures browsers, runs the tests and exits
  48. singleRun: false
  49. });
  50. };