-
Notifications
You must be signed in to change notification settings - Fork 49
/
jest.config.js
49 lines (49 loc) · 1.12 KB
/
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
46
47
48
49
module.exports = {
preset: 'ts-jest',
testEnvironment: 'node',
clearMocks: true,
runner: 'groups',
testTimeout: 6000,
setupFilesAfterEnv: ['../jest-setup/setup.js'],
transformIgnorePatterns: [
'/node_modules/(?!@polkadot|@babel/runtime/helpers/esm/)',
],
coverageThreshold: {
global: {
branches: 70,
functions: 80,
lines: 80,
statements: 80,
},
},
transform: {
'\\.js$': 'babel-jest',
'\\.ts$': 'ts-jest',
},
collectCoverageFrom: [
'**/*/src/**/*.ts',
'!**/index.ts',
'!**/__integrationtests__/**',
'!**/__mocks__/**',
'!**/__tests__/**',
'!**/lib/**',
'!**/test/**',
'!**/cord/*',
'!**/types/**/*',
'!**/SDKErrors.ts',
'!utils/src/json-schema/*',
'!testing/**',
'!augment-api/**',
'!type-definitions/**',
'!**/*.chain.ts',
'!did/src/Did.chain.ts',
'!did/src/Did.rpc.ts',
'!did/src/Did.utils.ts',
'!utils/src/jsonabc.ts',
'!modules/src/utils.ts',
],
resolver: 'ts-jest-resolver',
rootDir: 'packages',
coverageDirectory: 'coverage',
moduleDirectories: ['node_modules', 'packages/*/src'],
}