diff --git a/jest.config.js b/jest.config.js index e97b0da..d05d74f 100644 --- a/jest.config.js +++ b/jest.config.js @@ -1,3 +1,13 @@ +// Module value in tsconfig is like `esnext` and erroneously triggers a diagnostic warning +// https://github.com/kulshekhar/ts-jest/issues/748 +const tsJestIgnore = { + 'ts-jest': { + diagnostics: { + ignoreCodes: [151001], + }, + }, +} + module.exports = { roots: [ '/src' @@ -7,4 +17,7 @@ module.exports = { }, testRegex: '(/__tests__/.*|(\\.|/)test)\\.ts?$', moduleFileExtensions: ['ts', 'js'], + globals: { + ...tsJestIgnore, + }, } \ No newline at end of file