-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathjest.config.ts
More file actions
28 lines (23 loc) · 794 Bytes
/
jest.config.ts
File metadata and controls
28 lines (23 loc) · 794 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
28
/**
* For a detailed explanation regarding each configuration property, visit:
* https://jestjs.io/docs/configuration
*/
import type { Config } from "jest";
const config: Config = {
moduleNameMapper: {
"^@rnaga/wp-node/(.*)$": "<rootDir>/packages/core/src/$1",
"^@rnaga/wp-node-cli/(.*)$": "<rootDir>/packages/cli/src/$1",
},
// exclude dist folders to avoid collision error - jest-haste-map: Haste module naming collision
modulePathIgnorePatterns: [
"<rootDir>/packages/cli/dist",
"<rootDir>/packages/core/dist",
],
setupFilesAfterEnv: ["./test/bootstrap.ts"],
coverageProvider: "v8",
testMatch: ["**/?(*.)+(spec|test).+(ts|tsx|js)"],
transform: {
"^.+\\.(ts|tsx)$": ["ts-jest", { tsconfig: "test/tsconfig.json" }],
},
};
export default config;