-
Notifications
You must be signed in to change notification settings - Fork 79
Expand file tree
/
Copy pathjest.config.js
More file actions
31 lines (31 loc) · 838 Bytes
/
jest.config.js
File metadata and controls
31 lines (31 loc) · 838 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
module.exports = {
verbose: true,
testEnvironment: 'jsdom',
testTimeout: 10000,
coverageProvider: 'v8',
coverageReporters: ['json-summary', 'lcov', 'text'],
moduleDirectories: ['node_modules', 'src'],
modulePaths: ['<rootDir>/src'],
roots: ['<rootDir>/src'],
transform: {
'^.+\\.(ts|js|tsx|jsx)$': ['@swc/jest']
},
setupFilesAfterEnv: ['<rootDir>/src/setupTests.js'],
transformIgnorePatterns: ['node_modules/(^.+\\\\.(ts|js|tsx|jsx)$)'],
testMatch: [
'**/__tests__/**/*.[jt]s?(x)',
'**/?(*.)+(spec|test|bgTest).[jt]s?(x)'
],
moduleFileExtensions: [
// Place tsx and ts to beginning as suggestion from Jest team
// https://jestjs.io/docs/configuration#modulefileextensions-arraystring
'tsx',
'ts',
'web.js',
'js',
'web.ts',
'web.tsx',
'json',
'node'
]
};