mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
lint jest only for test files
This commit is contained in:
parent
84bd3aca6a
commit
0db94ea588
@ -5,7 +5,7 @@ module.exports = {
|
|||||||
node: true,
|
node: true,
|
||||||
},
|
},
|
||||||
parser: '@typescript-eslint/parser',
|
parser: '@typescript-eslint/parser',
|
||||||
plugins: ['prettier', '@typescript-eslint', 'type-graphql', 'jest', 'import', 'n'],
|
plugins: ['prettier', '@typescript-eslint', 'type-graphql', 'import', 'n'],
|
||||||
extends: [
|
extends: [
|
||||||
'standard',
|
'standard',
|
||||||
'eslint:recommended',
|
'eslint:recommended',
|
||||||
@ -33,12 +33,6 @@ module.exports = {
|
|||||||
htmlWhitespaceSensitivity: 'ignore',
|
htmlWhitespaceSensitivity: 'ignore',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
// jest
|
|
||||||
'jest/no-disabled-tests': 'error',
|
|
||||||
'jest/no-focused-tests': 'error',
|
|
||||||
'jest/no-identical-title': 'error',
|
|
||||||
'jest/prefer-to-have-length': 'error',
|
|
||||||
'jest/valid-expect': 'error',
|
|
||||||
// import
|
// import
|
||||||
'import/export': 'error',
|
'import/export': 'error',
|
||||||
'import/no-deprecated': 'error',
|
'import/no-deprecated': 'error',
|
||||||
@ -168,5 +162,18 @@ module.exports = {
|
|||||||
EXPERIMENTAL_useSourceOfProjectReferenceRedirect: true,
|
EXPERIMENTAL_useSourceOfProjectReferenceRedirect: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
files: ['*.test.ts'],
|
||||||
|
plugins: ['jest'],
|
||||||
|
rules: {
|
||||||
|
'jest/no-disabled-tests': 'error',
|
||||||
|
'jest/no-focused-tests': 'error',
|
||||||
|
'jest/no-identical-title': 'error',
|
||||||
|
'jest/prefer-to-have-length': 'error',
|
||||||
|
'jest/valid-expect': 'error',
|
||||||
|
'@typescript-eslint/unbound-method': 'off',
|
||||||
|
'jest/unbound-method': 'error',
|
||||||
|
},
|
||||||
|
},
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user