-
-
Notifications
You must be signed in to change notification settings - Fork 31.9k
test_runner: recalculate run duration on watch restart #57786
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test_runner: recalculate run duration on watch restart #57786
Conversation
Review requested:
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #57786 +/- ##
==========================================
+ Coverage 90.22% 90.24% +0.02%
==========================================
Files 630 630
Lines 185233 185678 +445
Branches 36325 36391 +66
==========================================
+ Hits 167122 167567 +445
+ Misses 11020 10996 -24
- Partials 7091 7115 +24
🚀 New features to boost your workflow:
|
Commit Queue failed- Loading data for nodejs/node/pull/57786 ✔ Done loading data for nodejs/node/pull/57786 ----------------------------------- PR info ------------------------------------ Title test_runner: recalculate run duration on watch restart (#57786) Author Pietro Marchini <pietro.marchini94@gmail.com> (@pmarchini) Branch pmarchini:test_runner/fix/test-runner-watch-duration-update -> nodejs:main Labels author ready, needs-ci, test_runner Commits 4 - test_runner: recalculate run duration on watch restart - test_runner: rename method to clearExecutionTime for clarity - fixup! test_runner: rename method to clearExecutionTime for clarity - test: lint tests Committers 1 - Pietro Marchini <pietro.marchini94@gmail.com> PR-URL: https://github.com/nodejs/node/pull/57786 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> ------------------------------ Generated metadata ------------------------------ PR-URL: https://github.com/nodejs/node/pull/57786 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> -------------------------------------------------------------------------------- ℹ This PR was created on Mon, 07 Apr 2025 20:48:01 GMT ✔ Approvals: 2 ✔ - Benjamin Gruenbaum (@benjamingr) (TSC): https://github.com/nodejs/node/pull/57786#pullrequestreview-2767394183 ✔ - Marco Ippolito (@marco-ippolito) (TSC): https://github.com/nodejs/node/pull/57786#pullrequestreview-2769240500 ✔ Last GitHub CI successful ℹ Last Full PR CI on 2025-04-16T13:07:46Z: https://ci.nodejs.org/job/node-test-pull-request/66304/ - Querying data for job/node-test-pull-request/66304/ ✔ Last Jenkins CI successful -------------------------------------------------------------------------------- ✔ No git cherry-pick in progress ✔ No git am in progress ✔ No git rebase in progress -------------------------------------------------------------------------------- - Bringing origin/main up to date... From https://github.com/nodejs/node * branch main -> FETCH_HEAD ✔ origin/main is now up-to-date - Downloading patch for 57786 From https://github.com/nodejs/node * branch refs/pull/57786/merge -> FETCH_HEAD ✔ Fetched commits as 5077ea41491d..121e36088b32 -------------------------------------------------------------------------------- Auto-merging lib/internal/test_runner/runner.js Auto-merging lib/internal/test_runner/test.js [main 6e8c7c9d5f] test_runner: recalculate run duration on watch restart Author: Pietro Marchini <pietro.marchini94@gmail.com> Date: Mon Apr 7 22:45:29 2025 +0200 3 files changed, 25 insertions(+), 1 deletion(-) Auto-merging lib/internal/test_runner/runner.js Auto-merging lib/internal/test_runner/test.js [main 178cabf5a1] test_runner: rename method to clearExecutionTime for clarity Author: Pietro Marchini <pietro.marchini94@gmail.com> Date: Mon Apr 14 12:16:44 2025 +0200 2 files changed, 2 insertions(+), 2 deletions(-) Auto-merging lib/internal/test_runner/runner.js [main 04b2484f55] fixup! test_runner: rename method to clearExecutionTime for clarity Author: Pietro Marchini <pietro.marchini94@gmail.com> Date: Mon Apr 14 12:19:13 2025 +0200 1 file changed, 1 insertion(+), 1 deletion(-) [main 2dea2d5d54] test: lint tests Author: Pietro Marchini <pietro.marchini94@gmail.com> Date: Mon Apr 14 17:03:56 2025 +0200 1 file changed, 4 insertions(+), 4 deletions(-) ✔ Patches applied There are 4 commits in the PR. Attempting autorebase. Rebasing (2/7) Executing: git node land --amend --yes --------------------------------- New Message ---------------------------------- test_runner: recalculate run duration on watch restarthttps://github.com/nodejs/node/actions/runs/14494776822 |
Landed in 8e4e4df |
PR-URL: #57786 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
PR-URL: #57786 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Re-running a test using the
--watch
flag keeps the duration unchanged across the various reruns.I've drafted a trivial implementation.
The test I introduced is flaky by design; I need to consider a better approach even though the number of digits is high and the likelihood of getting the same number in two consecutive runs is really low.