Avoid running tests twice

Jest was running both the test/xyz.ts version of the test files and
the compiled dist/test/xyz.js version of the test. Removing this
duplication also prevents the tests from failing.
This commit is contained in:
Jeroen Engels 2021-11-20 13:57:17 +01:00
parent 088c438577
commit c4972e720b

View File

@ -4,9 +4,9 @@ function createJestConfig(_, rootDir = __dirname) {
'.(ts|tsx)$': 'ts-jest'
},
transformIgnorePatterns: ['[/\\\\]node_modules[/\\\\].+\\.(js|jsx)$'],
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'node'],
moduleFileExtensions: ['ts', 'js'],
collectCoverageFrom: ['src/**/*.{ts,tsx,js,jsx}'],
testMatch: ['<rootDir>/**/*.(spec|test).{ts,tsx,js,jsx}'],
testMatch: ['<rootDir>/test/*.(spec|test).ts'],
testURL: 'http://localhost',
rootDir,
watchPlugins: [