blob: 9c9af41ab39f87c740d8abf81bde263b67ac1fd1 [file] [log] [blame]
Simon Hunt449630f2014-12-09 11:40:00 -08001// Karma configuration
Simon Hunt449630f2014-12-09 11:40:00 -08002
3module.exports = function(config) {
4 config.set({
5
6 // base path that will be used to resolve all patterns (eg. files, exclude)
Simon Hunt5d12dc22015-01-05 16:56:22 -08007 // the path is relative to this (karma.conf.js) file
Simon Hunt449630f2014-12-09 11:40:00 -08008 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: [
Simon Huntf3069722014-12-16 18:15:37 -080018 // library code...
19 '../tp/angular.js',
20 '../tp/angular-mocks.js',
Simon Hunt5d12dc22015-01-05 16:56:22 -080021 '../tp/angular-route.js',
Simon Huntf3069722014-12-16 18:15:37 -080022 '../tp/d3.js',
23 '../tp/topojson.v1.min.js',
Simon Huntf3069722014-12-16 18:15:37 -080024
25 // production code...
Simon Huntdc6362a2014-12-18 19:55:23 -080026 // make sure modules are defined first...
Simon Huntf3069722014-12-16 18:15:37 -080027 '../app/onos.js',
Simon Hunt0541fb82015-01-14 18:59:57 -080028 '../app/directives.js',
Simon Huntdc6362a2014-12-18 19:55:23 -080029 '../app/fw/util/util.js',
Simon Hunt7ac7be92015-01-06 10:47:56 -080030 '../app/fw/svg/svg.js',
Simon Hunte6720442015-01-15 12:21:06 -080031 '../app/fw/remote/remote.js',
Simon Huntdc6362a2014-12-18 19:55:23 -080032 // now load services etc. that augment the modules
33 '../app/**/*.js',
Simon Huntf3069722014-12-16 18:15:37 -080034
35 // unit test code...
Simon Huntdc6362a2014-12-18 19:55:23 -080036 'app/*-spec.js',
37 'app/**/*-spec.js'
Simon Hunt449630f2014-12-09 11:40:00 -080038 ],
39
40
41 // list of files to exclude
42 exclude: [
43 ],
44
45
46 // preprocess matching files before serving them to the browser
47 // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
48 preprocessors: {
49 },
50
51
52 // test results reporter to use
53 // possible values: 'dots', 'progress'
54 // available reporters: https://npmjs.org/browse/keyword/karma-reporter
55 reporters: ['progress'],
56
57
58 // web server port
59 port: 9876,
60
61
62 // enable / disable colors in the output (reporters and logs)
63 colors: true,
64
65
66 // level of logging
67 // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
68 logLevel: config.LOG_INFO,
69
70
71 // enable / disable watching file and executing tests whenever any file changes
72 autoWatch: true,
73
74
75 // start these browsers
76 // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
77 browsers: ['Chrome'],
78
79
80 // Continuous Integration mode
81 // if true, Karma captures browsers, runs the tests and exits
82 singleRun: false
83 });
84};