forked from bsv-blockchain/ts-stack
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjest.config.ts
More file actions
27 lines (25 loc) · 844 Bytes
/
Copy pathjest.config.ts
File metadata and controls
27 lines (25 loc) · 844 Bytes
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
import type { Config } from 'jest';
//import { defaults } from 'jest-config'
async function jestConfig(): Promise<Config> {
//console.log(defaults)
return {
bail: 1,
verbose: true,
// default is '.'
rootDir: '.',
// Must include source and test folders: default is ['<rootDir>']
roots: ["<rootDir>"],
// Speed up by restricting to module (source files) extensions used.
moduleFileExtensions: ['ts', 'js'],
// excluded source files...
modulePathIgnorePatterns: ['out/src', 'out/test'],
// Default is 'node'
testEnvironment: 'node',
// default [ '**/__tests__/**/*.[jt]s?(x)', '**/?(*.)+(spec|test).[tj]s?(x)' ]
testMatch: ['**/?(*.)+(test).[tj]s'],
// default []
testRegex: [],
transform: { '^.+\\.ts$': ['ts-jest', { 'rootDir': "." }] },
}
}
export default jestConfig