mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Fix failing transaction-list-item.component test by mocking useLayoutEffect (#12118)
This commit is contained in:
parent
f472c2615a
commit
cf569161fb
@ -63,6 +63,14 @@ setBackgroundConnection({
|
||||
getGasFeeEstimatesAndStartPolling: jest.fn(),
|
||||
});
|
||||
|
||||
jest.mock('react', () => {
|
||||
const originReact = jest.requireActual('react');
|
||||
return {
|
||||
...originReact,
|
||||
useLayoutEffect: jest.fn(),
|
||||
};
|
||||
});
|
||||
|
||||
const generateUseSelectorRouter = (opts) => (selector) => {
|
||||
if (selector === getConversionRate) {
|
||||
return 1;
|
||||
|
Loading…
Reference in New Issue
Block a user