forked from ark120202/eslint-config
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path+jest.js
More file actions
23 lines (23 loc) · 756 Bytes
/
Copy path+jest.js
File metadata and controls
23 lines (23 loc) · 756 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/** @type {import('eslint').Linter.Config} */
module.exports = {
extends: ['plugin:jest/recommended', 'plugin:jest/style'],
rules: {
'jest/expect-expect': 'off',
'jest/consistent-test-it': ['error', { fn: 'test', withinDescribe: 'test' }],
'jest/lowercase-name': 'error',
// TODO: Should be covered by a type-based rule
'jest/no-deprecated-functions': 'error',
'jest/no-restricted-matchers': [
'error',
{
resolves: 'Use `expect(await promise)` instead.',
toBeTruthy: 'Avoid `toBeTruthy`',
toBeFalsy: 'Avoid `toBeFalsy`',
},
],
'jest/no-test-return-statement': 'error',
'jest/prefer-spy-on': 'error',
'jest/prefer-todo': 'error',
'jest/valid-title': 'error',
},
};