-
Notifications
You must be signed in to change notification settings - Fork 4
/
jest.config.js
40 lines (39 loc) · 923 Bytes
/
jest.config.js
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
32
33
34
35
36
37
38
39
40
// eslint-disable-next-line @typescript-eslint/no-var-requires
module.exports = {
rootDir: process.cwd(),
coverageDirectory: '<rootDir>/.coverage',
globals: {
__DEV__: true,
},
collectCoverageFrom: [
'src/**/*.{js,jsx,ts,tsx}',
'!src/**/*.d.ts',
'!src/**/*.test.*',
'!src/test/**/*.*',
],
// setupFilesAfterEnv: [path.join(__dirname, './setupTests.ts')],
testMatch: [
'<rootDir>/**/?(*.)(spec|test).ts?(x)',
],
testEnvironment: 'node',
testURL: 'http://localhost',
transform: {
'^.+\\.(ts|tsx)$': 'ts-jest',
},
transformIgnorePatterns: ['[/\\\\]node_modules[/\\\\].+\\.(js|jsx)$'],
// testPathIgnorePatterns: ['<rootDir>/src/__tests__/test-utils.tsx'],
moduleNameMapper: {
'^react-native$': 'react-native-web',
},
moduleFileExtensions: [
'web.js',
'js',
'json',
'web.jsx',
'jsx',
'ts',
'tsx',
'feature',
'csv',
],
}