ESLint: Override config for tests

This is done to to fix Issue #1098

Signed-off-by: Philip Molares <philip.molares@udo.edu>
This commit is contained in:
Philip Molares 2021-04-12 17:02:47 +02:00
parent 2e1cbb3543
commit 5099f0f5c5

View file

@ -8,7 +8,26 @@ module.exports = {
project: 'tsconfig.json',
sourceType: 'module',
},
plugins: ['@typescript-eslint'],
overrides: [
{
files: ['test/**', 'src/**/*.spec.ts'],
extends: ['plugin:jest/recommended'],
rules: {
'@typescript-eslint/unbound-method': 'off',
'@typescript-eslint/no-unsafe-assignment': 'off',
'@typescript-eslint/no-unsafe-member-access': 'off',
'@typescript-eslint/require-await': 'off',
'jest/unbound-method': 'error',
'jest/expect-expect': [
'error',
{
assertFunctionNames: ['expect', 'request.**.expect'],
},
],
},
},
],
plugins: ['@typescript-eslint', 'jest'],
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',