-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathjest.config.ts
35 lines (28 loc) · 1.13 KB
/
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
/*
* For a detailed explanation regarding each configuration property and type check, visit:
* https://jestjs.io/docs/en/configuration.html
*/
import type { Config } from '@jest/types';
export default async (): Promise<Config.InitialOptions> => {
return {
// Indicates whether the coverage information should be collected while executing the test
collectCoverage: true,
// An array of glob patterns indicating a set of files for which coverage information should be collected
collectCoverageFrom: [
"src/*.ts",
"!src/*.d.ts"
],
// The directory where Jest should output its coverage files
coverageDirectory: "coverage",
// A list of reporter names that Jest uses when writing coverage reports
coverageReporters: [
"text"
],
// A preset that is used as a base for Jest's configuration
preset: "ts-jest",
// The root directory that Jest should scan for tests and modules within
rootDir: './',
// The test environment that will be used for testing
testEnvironment: "node",
};
};