GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( 043e72...5d2753 )
by Benjamin
06:48 queued 02:54
created

test/util/isPluginEnabled.test.js   A

Complexity

Total Complexity 7
Complexity/F 1

Size

Lines of Code 75
Function Count 7

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
cc 0
wmc 7
c 1
b 0
f 1
nc 1
mnd 0
bc 7
fnc 7
dl 0
loc 75
rs 10
bpm 1
cpm 1
noi 1
1
import expect from 'expect';
2
import { isPluginEnabled } from './../../src/util/isPluginEnabled';
3
4
describe('isPluginEnabled utility function', () => {
5
6
    it('Should return enabled', () => {
7
        const plugins = {
8
            BULK_ACTIONS: {
9
                enabled: true
10
            }
11
        };
12
13
        expect(isPluginEnabled(
14
            plugins, 'BULK_ACTIONS'
15
        )).toEqual(
16
            true
17
        );
18
    });
19
20
    it('Should return not enabled', () => {
21
        const plugins = {
22
            BULK_ACTIONS: {
23
                enabled: false
24
            }
25
        };
26
27
        expect(isPluginEnabled(
28
            plugins, 'BULK_ACTIONS'
29
        )).toEqual(
30
            false
31
        );
32
    });
33
34
    it('Should return not enabled', () => {
35
        const plugins = {};
36
37
        expect(isPluginEnabled(
38
            plugins, 'BULK_ACTIONS'
39
        )).toEqual(
40
            false
41
        );
42
    });
43
44
    it('Should return not enabled', () => {
45
        expect(isPluginEnabled(
46
            null, 'BULK_ACTIONS'
47
        )).toEqual(
48
            false
49
        );
50
    });
51
52
    it('Should return not enabled', () => {
53
        expect(isPluginEnabled(
54
            false, 'BULK_ACTIONS'
55
        )).toEqual(
56
            false
57
        );
58
    });
59
60
    it('Should return not enabled', () => {
61
            
62
         const plugins = {
63
            BULK_ACTIONS: {
64
                enabled: true
65
            }
66
        };
67
68
        expect(isPluginEnabled(
69
            false, 'BULK_ACTIS'
70
        )).toEqual(
71
            false
72
        );
73
    });
74
75
});