-
Notifications
You must be signed in to change notification settings - Fork 6
/
jest.js
67 lines (65 loc) · 2.3 KB
/
jest.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
'use strict';
module.exports = {
plugins: ['jest'],
env: {
'jest/globals': true
},
rules: {
'max-statements': 'off',
'jest/consistent-test-it': [
'error',
{
fn: 'it',
withinDescribe: 'it'
}
],
'jest/expect-expect': [
'error',
{
assertFunctionNames: ['expect']
}
],
'jest/prefer-lowercase-title': ['error'],
'jest/no-alias-methods': ['error'],
'jest/no-commented-out-tests': ['error'],
'jest/no-conditional-expect': ['error'],
'jest/no-deprecated-functions': ['error'],
'jest/no-disabled-tests': ['error'],
'jest/no-duplicate-hooks': ['error'],
'jest/no-export': ['error'],
'jest/no-focused-tests': ['error'],
'jest/no-hooks': ['error'],
'jest/no-identical-title': ['error'],
'jest/no-jasmine-globals': ['error'],
'jest/no-large-snapshots': ['error'],
'jest/no-standalone-expect': ['error'],
'jest/no-test-callback': ['error'],
'jest/no-test-prefixes': ['error'],
'jest/no-test-return-statement': ['error'],
'jest/prefer-called-with': ['error'],
'jest/prefer-strict-equal': ['error'],
'jest/prefer-to-be': ['error'],
'jest/prefer-to-contain': ['error'],
'jest/prefer-to-have-length': ['error'],
'jest/require-to-throw-message': ['error'],
'jest/require-top-level-describe': ['error'],
'jest/no-interpolation-in-snapshots': ['off'],
'jest/no-jest-import': ['off'],
'jest/no-mocks-import': ['off'],
'jest/no-restricted-matchers': ['off'],
'jest/prefer-expect-assertions': ['off'],
'jest/prefer-hooks-on-top': ['off'],
'jest/prefer-spy-on': ['off'],
'jest/prefer-todo': ['off'],
'jest/valid-describe-callback': ['off'],
'jest/valid-expect-in-promise': ['off'],
'jest/valid-expect': ['off'],
'jest/valid-title': ['off'],
'jest/no-if': ['off'],
'jest/no-done-callback': ['off'],
'jest/unbound-method': 'off',
'jest/max-nested-describe': ['error', { max: 4 }],
'jest/prefer-expect-resolves': 'warn',
'jest/require-hook': 'warn'
}
};