mirror of
https://github.com/element-hq/element-web
synced 2024-11-25 10:45:51 +03:00
mock out wasm imports in jest
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
parent
0032d7b943
commit
15894ed8bd
2 changed files with 2 additions and 0 deletions
1
__mocks__/wasmMock.js
Normal file
1
__mocks__/wasmMock.js
Normal file
|
@ -0,0 +1 @@
|
||||||
|
module.exports = "css-file-stub";
|
|
@ -215,6 +215,7 @@
|
||||||
"<rootDir>/node_modules/matrix-react-sdk/test/setupTests.js"
|
"<rootDir>/node_modules/matrix-react-sdk/test/setupTests.js"
|
||||||
],
|
],
|
||||||
"moduleNameMapper": {
|
"moduleNameMapper": {
|
||||||
|
"\\.wasm$": "<rootDir>/__mocks__/wasmMock.js",
|
||||||
"\\.(css|scss)$": "<rootDir>/__mocks__/cssMock.js",
|
"\\.(css|scss)$": "<rootDir>/__mocks__/cssMock.js",
|
||||||
"\\.(gif|png|svg|ttf|woff2)$": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/imageMock.js",
|
"\\.(gif|png|svg|ttf|woff2)$": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/imageMock.js",
|
||||||
"\\$webapp/i18n/languages.json": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/languages.json",
|
"\\$webapp/i18n/languages.json": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/languages.json",
|
||||||
|
|
Loading…
Reference in a new issue