2021-10-07 15:07:57 +00:00
|
|
|
import type { Config } from "@jest/types";
|
|
|
|
|
|
|
|
const config: Config.InitialOptions = {
|
|
|
|
verbose: true,
|
|
|
|
roots: ["<rootDir>"],
|
2022-07-21 16:44:23 +00:00
|
|
|
testMatch: ["**/test/lib/**/*.(spec|test).(ts|tsx|js)"],
|
2021-10-13 13:26:56 +00:00
|
|
|
testPathIgnorePatterns: ["<rootDir>/.next", "<rootDir>/playwright/"],
|
2021-10-07 15:07:57 +00:00
|
|
|
transform: {
|
|
|
|
"^.+\\.(js|jsx|ts|tsx)$": ["babel-jest", { presets: ["next/babel"] }],
|
|
|
|
},
|
|
|
|
transformIgnorePatterns: ["/node_modules/", "^.+\\.module\\.(css|sass|scss)$"],
|
|
|
|
testEnvironment: "jsdom",
|
|
|
|
moduleNameMapper: {
|
|
|
|
"^@components(.*)$": "<rootDir>/components$1",
|
|
|
|
"^@lib(.*)$": "<rootDir>/lib$1",
|
2021-10-25 13:05:21 +00:00
|
|
|
"^@server(.*)$": "<rootDir>/server$1",
|
2021-12-03 16:18:31 +00:00
|
|
|
"^@ee(.*)$": "<rootDir>/ee$1",
|
2021-10-07 15:07:57 +00:00
|
|
|
},
|
|
|
|
};
|
|
|
|
|
|
|
|
export default config;
|