This repository has been archived by the owner on Mar 15, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 13
/
karma.conf.js
67 lines (52 loc) · 2.19 KB
/
karma.conf.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/*
Karma configuration. Generated from marketplace-gulp/templates.
*/
var mktConfig = require('./config');
module.exports = function(config) {
config.set({
// Base path that will be used to resolve all patterns.
basePath: '',
// Frameworks to use
// Available frameworks: https://npmjs.org/browse/keyword/karma-adapter
// Include requirejs first or else chai complains.
frameworks: ['requirejs', 'chai', 'mocha', 'sinon'],
// List of files / patterns to load in the browser.
files: [
'test-main.js',
{pattern: 'bower_components/marketplace-core-modules/core/**/*.js',
included: false},
{pattern: 'bower_components/squire/src/Squire.js',
included: false},
{pattern: 'src/media/js/**/*.js', included: false},
{pattern: 'src/templates.js', included: false},
{pattern: 'tests/unit/*.js', included: false},
],
// List of files to exclude.
exclude: [
'src/media/js/lib/marketplace-core-modules/**/*',
],
// Preprocess matching files before serving them to the browser.
// Available PPs: https://npmjs.org/browse/keyword/karma-preprocessor
preprocessors: {
},
// Test results reporter to use.
// Available reporters: https://npmjs.org/browse/keyword/karma-reporter
reporters: ['mocha'],
// Web server port.
port: mktConfig.PORT ? mktConfig.PORT + 2000 : 9876,
// Enable / disable colors in the output (reporters and logs).
colors: true,
// Level of logging (config.LOG_DISABLE, config.LOG_ERROR,
// config.LOG_WARN || config.LOG_INFO ||
// config.LOG_DEBUG).
logLevel: config.LOG_INFO,
// File-watching and executing tests when a file changes.
autoWatch: true,
// Start these browsers.
// Available browsers: https://npmjs.org/browse/keyword/karma-launcher
browsers: ['Firefox'],
// Continuous Integration mode. If true, Karma captures browsers,
// runs tests and exits.
singleRun: false
});
};