[test optimization] Minor jest clean up#7777
Conversation
1. Clear testsToBeRetried, retriedTestsToNumAttempts, and attemptToFixRetriedTestsStatuses in the run_finish handler to prevent memory accumulation when a jest worker runs multiple test suites sequentially. Note: newTestsTestStatuses and testSuiteAbsolutePathsWithFastCheck are intentionally NOT cleared here because they are read after run_finish in the jestAdapterWrapper result processing. 2. Add null guard on the test context in the test_done handler. If testContexts has no entry for a test, log a warning and return early instead of throwing on ctx.currentStore access. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Overall package sizeSelf size: 4.96 MB Dependency sizes| name | version | self size | total size | |------|---------|-----------|------------| | import-in-the-middle | 3.0.0 | 81.15 kB | 815.98 kB | | dc-polyfill | 0.1.10 | 26.73 kB | 26.73 kB |🤖 This report was automatically generated by heaviest-objects-in-the-universe |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #7777 +/- ##
==========================================
- Coverage 80.43% 80.42% -0.01%
==========================================
Files 741 741
Lines 32173 32182 +9
==========================================
+ Hits 25877 25883 +6
- Misses 6296 6299 +3 Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
BenchmarksBenchmark execution time: 2026-03-13 15:35:04 Comparing candidate commit 0894b42 in PR branch Found 0 performance improvements and 0 performance regressions! Performance is the same for 231 metrics, 29 unstable metrics. |
What does this PR do?
Motivation
Additional Notes