-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjest.config.ts
47 lines (45 loc) · 959 Bytes
/
jest.config.ts
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
46
47
import type { Config } from 'jest';
const config: Config = {
collectCoverageFrom: ['**/*.ts'],
coverageDirectory: 'coverage',
coveragePathIgnorePatterns: [
'.*-config.service.ts',
'.*.config.ts',
'.*.dto.ts',
'.*.error.ts',
'.*.filter.ts',
'.*.input.ts',
'.*.module.ts',
'.*.result.ts',
'dist',
'index.ts',
'jest.config-coverage.ts',
'main.ts',
'node_modules',
'tests',
],
coverageReporters: ['lcov', 'clover', 'text-summary'],
coverageThreshold: {
global: {
branches: 80,
functions: 80,
lines: 80,
statements: 80,
},
},
moduleFileExtensions: ['js', 'json', 'ts'],
preset: 'ts-jest',
roots: ['<rootDir>'],
testEnvironment: 'node',
testRegex: '.*\\.spec\\.ts$',
transform: {
'^.+\\.ts$': [
'ts-jest',
{
ignoreCoverageForAllDecorators: true,
isolatedModules: false,
},
],
},
};
export default config;