Skip to content

Commit e684ca6

Browse files
authored
refactor[react-devtools/tests]: use registered marks instead of cleared in tests (facebook#29929)
## Summary This is the pre-requisite for facebook#29231. Current implementation of profiling hooks is only using `performance.mark` and then makes `performance.clearMarks` call right after it to free the memory. We've been relying on this assumption in the tests that every mark is cleared by the time we check something. facebook#29231 adds `performance.measure` calls and the `start` mark is not cleared until the corresponding `stop` one is registered, and then they are cleared together. ## How did you test this change? To test against React from source: ``` yarn test --build --project=devtools -r=experimental --ci ``` To test against React 18: ``` ./scripts/circleci/download_devtools_regression_build.js 18.0 --replaceBuild node ./scripts/jest/jest-cli.js --build --project devtools --release-channel=experimental --reactVersion 18.0 --ci ```
1 parent 83d538e commit e684ca6

File tree

2 files changed

+101
-99
lines changed

2 files changed

+101
-99
lines changed

0 commit comments

Comments
 (0)