Browse Source

mock out scss imports for jest

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
t3chguy/app_load4
Michael Telatynski 1 year ago
parent
commit
6584ff29af
  1. 1
      __mocks__/cssMock.js
  2. 1
      package.json

1
__mocks__/cssMock.js

@ -0,0 +1 @@
module.exports = "css-file-stub";

1
package.json

@ -215,6 +215,7 @@
"<rootDir>/node_modules/matrix-react-sdk/test/setupTests.js"
],
"moduleNameMapper": {
"\\.(css|scss)$": "<rootDir>/__mocks__/cssMock.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",
"^browser-request$": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/browser-request.js",

Loading…
Cancel
Save