Removed support for css-modules (for now) in tests and fixed css/scss imports from node_modules
This commit is contained in:
parent
63b8559d7e
commit
d39c9cee2c
@ -35,8 +35,7 @@
|
|||||||
"jest": {
|
"jest": {
|
||||||
"moduleNameMapper": {
|
"moduleNameMapper": {
|
||||||
"^.+\\.(png|eot|woff|woff2|ttf|svg|gif)$": "<rootDir>/__mocks__/fileLoaderMock.js",
|
"^.+\\.(png|eot|woff|woff2|ttf|svg|gif)$": "<rootDir>/__mocks__/fileLoaderMock.js",
|
||||||
"^.+\\.scss$": "<rootDir>/__mocks__/styleLoaderMock.js",
|
"^.+\\.s?css$": "<rootDir>/__mocks__/styleLoaderMock.js"
|
||||||
"^.+\\.css$": "identity-obj-proxy"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
@ -9,6 +9,7 @@ module.exports = wallaby => ({
|
|||||||
'src/**/*.js',
|
'src/**/*.js',
|
||||||
'src/**/*.js.snap',
|
'src/**/*.js.snap',
|
||||||
'!src/**/*.spec.js',
|
'!src/**/*.spec.js',
|
||||||
|
{ pattern: 'src/**/*.css', instrument: false },
|
||||||
],
|
],
|
||||||
|
|
||||||
tests: ['src/**/*.spec.js'],
|
tests: ['src/**/*.spec.js'],
|
||||||
@ -31,8 +32,7 @@ module.exports = wallaby => ({
|
|||||||
wallaby.testFramework.configure({
|
wallaby.testFramework.configure({
|
||||||
moduleNameMapper: {
|
moduleNameMapper: {
|
||||||
'^.+\\.(png|eot|woff|woff2|ttf|svg|gif)$': require('path').join(wallaby.localProjectDir, '__mocks__', 'fileLoaderMock.js'),
|
'^.+\\.(png|eot|woff|woff2|ttf|svg|gif)$': require('path').join(wallaby.localProjectDir, '__mocks__', 'fileLoaderMock.js'),
|
||||||
'^.+\\.scss$': require('path').join(wallaby.localProjectDir, '__mocks__', 'styleLoaderMock.js'),
|
'^.+\\.s?css$': require('path').join(wallaby.localProjectDir, '__mocks__', 'styleLoaderMock.js'),
|
||||||
'^.+\\.css$': require('identity-obj-proxy'),
|
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user