karma.conf.js   A
last analyzed

Complexity

Total Complexity 3
Complexity/F 3

Size

Lines of Code 69
Function Count 1

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 2
nc 2
dl 0
loc 69
rs 10
c 0
b 0
f 0
wmc 3
mnd 1
bc 2
fnc 1
bpm 2
cpm 3
noi 0

1 Function

Rating   Name   Duplication   Size   Complexity  
A module.exports 0 64 1
1
// Karma configuration
2
// Generated on Mon Oct 17 2016 15:46:52 GMT+0200 (CEST)
3
var isTravis = (process.env.TRAVIS_BUILD_NUMBER) ? true : false;
4
var browsers = ['Firefox'];
5
if(!isTravis){
6
    browsers = ['Chrome'];
7
}
8
module.exports = function (config) {
9
    config.set({
10
11
        // base path that will be used to resolve all patterns (eg. files, exclude)
12
        basePath: '.',
13
14
15
        // frameworks to use
16
        // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
17
        frameworks: ['jasmine'],
18
19
20
        // list of files / patterns to load in the browser
21
        files: [
22
            'js/lib/data/tlds.js',
23
            'js/lib/parseTLD.js',
24
            'js/lib/parseUrl.js',
25
            { pattern: 'tests/**/*.js', included: true }
26
        ],
27
28
29
        // list of files to exclude
30
        exclude: [
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
        // test results reporter to use
40
        // possible values: 'dots', 'progress'
41
        // available reporters: https://npmjs.org/browse/keyword/karma-reporter
42
        reporters: ['verbose'],
43
44
45
        // web server port
46
        port: 9876,
47
48
49
        // enable / disable colors in the output (reporters and logs)
50
        colors: true,
51
52
53
        // level of logging
54
        // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
55
        logLevel: config.LOG_INFO,
56
57
58
        // enable / disable watching file and executing tests whenever any file changes
59
        autoWatch: false,
60
61
62
        // start these browsers
63
        // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
64
        browsers: browsers,
65
66
67
        // Continuous Integration mode
68
        // if true, Karma captures browsers, runs the tests and exits
69
        singleRun: true
70
    });
71
};