Skip to content

Commit 28cd2eb

Browse files
committed
Update jest.config.ts
1 parent 78dc748 commit 28cd2eb

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

course-matrix/backend/jest.config.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,12 @@ import type { Config } from "jest";
22

33
const config: Config = {
44
preset: "ts-jest",
5-
moduleNameMapper: { "\\.(css|scss)$": "identity-obj-proxy" },
5+
moduleNameMapper: {
6+
"\\.(css|scss)$": "identity-obj-proxy",
7+
"^.+\\.svg": "<rootDir>/tests/mocks/svgMock.tsx",
8+
},
69
// to obtain access to the matchers.
10+
setupFilesAfterEnv: ["<rootDir>/tests/setupTests.ts"],
711
moduleFileExtensions: ["ts", "tsx", "js", "jsx", "json", "node"],
812
modulePaths: ["<rootDir>"],
913
testEnvironment: "jsdom",
@@ -18,4 +22,4 @@ const config: Config = {
1822
},
1923
};
2024

21-
export default config;
25+
export default config;

0 commit comments

Comments
 (0)