-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathjest.config.js
45 lines (45 loc) · 901 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
41
42
43
44
45
module.exports = {
coveragePathIgnorePatterns: [
'.*\\.d\\.ts',
],
collectCoverageFrom: [
'src/**/*.{js,jsx,ts,tsx}',
],
testPathIgnorePatterns: [
'<rootDir>/node_modules/',
],
testEnvironment: 'node',
testURL: 'http://localhost',
testMatch: [
'<rootDir>/src/**/?(*.)(spec|test).ts?(x)',
'<rootDir>/src/**/__tests__/**/*.ts?(x)',
],
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
transformIgnorePatterns: [
'[/\\\\]node_modules[/\\\\](?!(lodash-es|reach-router-hash-history)/.*).+\\.(js|jsx|ts|tsx)$',
],
moduleNameMapper: {
'^.+\\.(css|scss)$': 'identity-obj-proxy',
},
moduleFileExtensions: [
'js',
'json',
'jsx',
'node',
'ts',
'tsx',
'web.js',
'web.jsx',
'web.ts',
'web.tsx',
],
globals: {
window: {},
},
reporters: [
'default',
],
preset: 'ts-jest/presets/js-with-ts',
}