fix: update tests for dk0 logo and boneyard-js mock, add jest moduleNameMapper
This commit is contained in:
@@ -16,11 +16,12 @@ const config: Config = {
|
||||
testPathIgnorePatterns: ["/node_modules/", "/__mocks__/", "/.next/", "/e2e/"],
|
||||
// Transform react-markdown and other ESM modules
|
||||
transformIgnorePatterns: [
|
||||
"node_modules/(?!(react-markdown|remark-.*|rehype-.*|unified|bail|is-plain-obj|trough|vfile|vfile-message|unist-.*|micromark|parse-entities|character-entities|mdast-.*|hast-.*|property-information|space-separated-tokens|comma-separated-tokens|web-namespaces|zwitch|longest-streak|ccount)/)",
|
||||
"node_modules/(?!(react-markdown|remark-.*|rehype-.*|unified|bail|is-plain-obj|trough|vfile|vfile-message|unist-.*|micromark|parse-entities|character-entities|mdast-.*|hast-.*|property-information|space-separated-tokens|comma-separated-tokens|web-namespaces|zwitch|longest-streak|ccount|boneyard-js)/)",
|
||||
],
|
||||
// Module name mapping to fix haste collision
|
||||
moduleNameMapper: {
|
||||
"^@/(.*)$": "<rootDir>/$1",
|
||||
"^boneyard-js/react$": "<rootDir>/__mocks__/boneyard-js/react.tsx",
|
||||
},
|
||||
// Exclude problematic directories from haste
|
||||
modulePathIgnorePatterns: ["<rootDir>/.next/", "<rootDir>/node_modules/", "<rootDir>/e2e/"],
|
||||
|
||||
Reference in New Issue
Block a user