mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Mock <Trans /> from @lingui/macro as a component simplely returns children components
Signed-off-by: Hung-Han (Henry) Chen <chenhungh@gmail.com> Signed-off-by: Hung-Han (Henry) Chen <1474479+chenhunghan@users.noreply.github.com>
This commit is contained in:
parent
7a2da15828
commit
2b2499107f
3
__mocks__/@linguiMacro.ts
Normal file
3
__mocks__/@linguiMacro.ts
Normal file
@ -0,0 +1,3 @@
|
||||
module.exports = {
|
||||
Trans: ({ children }: { children: React.ReactNode }) => children,
|
||||
};
|
||||
@ -71,7 +71,8 @@
|
||||
"^.+\\.tsx?$": "ts-jest"
|
||||
},
|
||||
"moduleNameMapper": {
|
||||
"\\.(css|scss)$": "<rootDir>/__mocks__/styleMock.ts"
|
||||
"\\.(css|scss)$": "<rootDir>/__mocks__/styleMock.ts",
|
||||
"^@lingui/macro$": "<rootDir>/__mocks__/@linguiMacro.ts"
|
||||
},
|
||||
"modulePathIgnorePatterns": [
|
||||
"<rootDir>/dist"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user