fix: test problems jest dom and paragon (#311)
This commit is contained in:
@@ -18,4 +18,8 @@ module.exports = createConfig('jest', {
|
||||
],
|
||||
testTimeout: 120000,
|
||||
testEnvironment: 'jsdom',
|
||||
moduleNameMapper: {
|
||||
'^@openedx/paragon$': '<rootDir>/mockParagon.js',
|
||||
'^@openedx/paragon/(.*)$': '<rootDir>/mockParagon.js',
|
||||
},
|
||||
});
|
||||
|
||||
1
mockParagon.js
Normal file
1
mockParagon.js
Normal file
@@ -0,0 +1 @@
|
||||
module.exports = {};
|
||||
@@ -1,6 +1,6 @@
|
||||
/* eslint-disable import/no-extraneous-dependencies */
|
||||
import '@testing-library/jest-dom';
|
||||
import '@testing-library/jest-dom/extend-expect';
|
||||
// breaking change here: https://github.com/testing-library/jest-dom/releases/tag/v6.0.0
|
||||
|
||||
import Enzyme from 'enzyme';
|
||||
import Adapter from '@wojtekmaj/enzyme-adapter-react-17';
|
||||
|
||||
Reference in New Issue
Block a user