Skip to content

Commit

Permalink
fix: partially revert jest setup config removal to fix regression tests
Browse files Browse the repository at this point in the history
  • Loading branch information
hoxyq committed Feb 5, 2024
1 parent 596827f commit 650c622
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
2 changes: 2 additions & 0 deletions scripts/jest/devtools/config.build-devtools-regression.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ if (REACT_VERSION) {
'^react-dom/client$'
] = `<rootDir>/build/${NODE_MODULES_DIR}/react-dom`;
}

setupFiles.push(require.resolve('./setupTests.build-devtools-regression'));
}

module.exports = {
Expand Down
7 changes: 7 additions & 0 deletions scripts/jest/devtools/setupTests.build-devtools-regression.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
'use strict';

// Regression tests use a React DOM profiling, so we need
// to replace these tests with scheduler/tracing-profiling
jest.mock('scheduler/tracing', () => {
return jest.requireActual('scheduler/tracing-profiling');
});

0 comments on commit 650c622

Please sign in to comment.