|
| 1 | +// Karma configuration |
| 2 | +// Generated on Sat Mar 28 2015 11:17:34 GMT-0700 (PDT) |
1 | 3 |
|
2 |
| -// base path, that will be used to resolve files and exclude |
3 |
| -basePath = '.'; |
4 |
| - |
5 |
| -// list of files / patterns to load in the browser |
6 |
| -files = [ |
7 |
| - JASMINE, |
8 |
| - JASMINE_ADAPTER, |
9 |
| - 'misc/test-lib/jquery-1.8.2.min.js', |
10 |
| - 'misc/test-lib/angular.js', |
11 |
| - 'misc/test-lib/angular-mocks.js', |
12 |
| - 'misc/test-lib/angular-sanitize.js', |
13 |
| - 'misc/test-lib/helpers.js', |
14 |
| - 'src/**/*.js', |
15 |
| - 'template/**/*.js' |
16 |
| -]; |
17 |
| - |
18 |
| -// list of files to exclude |
19 |
| -exclude = [ |
20 |
| - 'src/**/docs/*' |
21 |
| -]; |
22 |
| - |
23 |
| -// Start these browsers, currently available: |
24 |
| -// - Chrome |
25 |
| -// - ChromeCanary |
26 |
| -// - Firefox |
27 |
| -// - Opera |
28 |
| -// - Safari |
29 |
| -// - PhantomJS |
30 |
| -browsers = [ |
31 |
| - 'Chrome' |
32 |
| -]; |
33 |
| - |
34 |
| -// test results reporter to use |
35 |
| -// possible values: dots || progress |
36 |
| -reporters = ['progress']; |
37 |
| - |
38 |
| -reportSlowerThan = 100; |
39 |
| - |
40 |
| -// web server port |
41 |
| -port = 9018; |
42 |
| - |
43 |
| -// cli runner port |
44 |
| -runnerPort = 9100; |
45 |
| - |
46 |
| -// enable / disable colors in the output (reporters and logs) |
47 |
| -colors = true; |
48 |
| - |
49 |
| -// level of logging |
50 |
| -// possible values: LOG_DISABLE || LOG_ERROR || LOG_WARN || LOG_INFO || LOG_DEBUG |
51 |
| -logLevel = LOG_INFO; |
52 |
| - |
53 |
| -// enable / disable watching file and executing tests whenever any file changes |
54 |
| -autoWatch = false; |
55 |
| - |
56 |
| -// Continuous Integration mode |
57 |
| -// if true, it capture browsers, run tests and exit |
58 |
| -singleRun = false; |
| 4 | +module.exports = function(config) { |
| 5 | + config.set({ |
59 | 6 |
|
| 7 | + // base path that will be used to resolve all patterns (eg. files, exclude) |
| 8 | + basePath: '', |
| 9 | + |
| 10 | + |
| 11 | + // frameworks to use |
| 12 | + // available frameworks: https://npmjs.org/browse/keyword/karma-adapter |
| 13 | + frameworks: ['jasmine'], |
| 14 | + |
| 15 | + |
| 16 | + // list of files / patterns to load in the browser |
| 17 | + files: [ |
| 18 | + 'misc/test-lib/jquery-1.8.2.min.js', |
| 19 | + 'node_modules/angular/angular.js', |
| 20 | + 'node_modules/angular-mocks/angular-mocks.js', |
| 21 | + 'node_modules/angular-sanitize/angular-sanitize.js', |
| 22 | + 'misc/test-lib/helpers.js', |
| 23 | + 'src/**/*.js', |
| 24 | + 'template/**/*.js' |
| 25 | + ], |
| 26 | + |
| 27 | + |
| 28 | + // list of files to exclude |
| 29 | + exclude: [ |
| 30 | + 'src/**/docs/*' |
| 31 | + ], |
| 32 | + |
| 33 | + |
| 34 | + // preprocess matching files before serving them to the browser |
| 35 | + // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor |
| 36 | + preprocessors: { |
| 37 | + }, |
| 38 | + |
| 39 | + |
| 40 | + // test results reporter to use |
| 41 | + // possible values: 'dots', 'progress' |
| 42 | + // available reporters: https://npmjs.org/browse/keyword/karma-reporter |
| 43 | + reporters: ['progress'], |
| 44 | + |
| 45 | + reportSlowerThan: 100, |
| 46 | + |
| 47 | + // web server port |
| 48 | + port: 9876, |
| 49 | + |
| 50 | + |
| 51 | + // enable / disable colors in the output (reporters and logs) |
| 52 | + colors: true, |
| 53 | + |
| 54 | + |
| 55 | + // level of logging |
| 56 | + // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG |
| 57 | + logLevel: config.LOG_INFO, |
| 58 | + |
| 59 | + |
| 60 | + // enable / disable watching file and executing tests whenever any file changes |
| 61 | + autoWatch: false, |
| 62 | + |
| 63 | + |
| 64 | + // start these browsers |
| 65 | + // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher |
| 66 | + browsers: ['Chrome'], |
| 67 | + |
| 68 | + |
| 69 | + // Continuous Integration mode |
| 70 | + // if true, Karma captures browsers, runs the tests and exits |
| 71 | + singleRun: false |
| 72 | + }); |
| 73 | +}; |
0 commit comments