-
Notifications
You must be signed in to change notification settings - Fork 28
/
jest.config.js
35 lines (34 loc) · 934 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
/* eslint-disable no-undef */
const { pathsToModuleNameMapper } = require('ts-jest');
// Path aliases from tsconfig.json
const {
compilerOptions: { paths },
} = require('./tsconfig.json');
const base = require('@substrate/dev/config/jest');
module.exports = {
...base,
verbose: true,
coverageThreshold: {
global: {
branches: 50,
functions: 70,
lines: 70,
statements: 85
}
},
testEnvironment: 'node',
testPathIgnorePatterns: ['lib', 'node_modules'],
moduleNameMapper: pathsToModuleNameMapper(paths, {
prefix: '<rootDir>/packages',
}),
modulePathIgnorePatterns: [
'<rootDir>/lib',
'<rootDir>/packages/txwrapper-core/lib',
'<rootDir>/packages/txwrapper-examples/lib',
'<rootDir>/packages/txwrapper-dev/lib',
'<rootDir>/packages/txwrapper-orml/lib',
'<rootDir>/packages/txwrapper-polkadot/lib',
'<rootDir>/packages/txwrapper-registry/lib',
'<rootDir>/packages/txwrapper-substrate/lib',
],
};