Skip to content

Commit

Permalink
Fix $app/env.js reference in Jest tests
Browse files Browse the repository at this point in the history
  • Loading branch information
florimondmanca committed Feb 1, 2022
1 parent 786d5b8 commit 6ae7c9a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 1 addition & 4 deletions client/jest.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,7 @@ module.exports = {
moduleFileExtensions: ["js", "ts", "svelte"],
moduleNameMapper: {
"^\\$lib(.*)$": "<rootDir>/src/lib$1",
"^\\$app(.*)$": [
"<rootDir>/.svelte-kit/dev/runtime/app$1",
"<rootDir>/.svelte-kit/build/runtime/app$1",
],
"^\\$app(.*)$": "<rootDir>/src/__tests__/appMock.cjs",
},
setupFilesAfterEnv: ["<rootDir>/jest-setup.ts"],
collectCoverageFrom: ["src/**/*.{ts,tsx,svelte,js,jsx}"],
Expand Down
4 changes: 4 additions & 0 deletions client/src/__tests__/appMock.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module.exports = {
dev: false,
browser: false,
}

0 comments on commit 6ae7c9a

Please sign in to comment.