From 08a9ba73e458b3a1a96eff19ad579a35cb2932ee Mon Sep 17 00:00:00 2001 From: Moshe Atlow Date: Mon, 30 Mar 2026 17:08:19 +0300 Subject: [PATCH] doc: mention test runner retry attemp is zero based PR-URL: https://github.com/nodejs/node/pull/62504 Reviewed-By: Chemi Atlow Reviewed-By: Benjamin Gruenbaum Reviewed-By: Pietro Marchini --- doc/api/test.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/doc/api/test.md b/doc/api/test.md index e05685c1421..48dee7d5610 100644 --- a/doc/api/test.md +++ b/doc/api/test.md @@ -3913,7 +3913,9 @@ added: v25.0.0 * Type: {number} -Number of times the test has been attempted. +The attempt number of the test. This value is zero-based, so the first attempt is `0`, +the second attempt is `1`, and so on. This property is useful in conjunction with the +`--test-rerun-failures` option to determine which attempt the test is currently running. ### `context.workerId` @@ -4286,9 +4288,9 @@ added: REPLACEME * Type: {number} -The current attempt number of the suite. Used in conjunction with the -`--test-rerun-failures` option to determine the attempt number of the current -run. +The attempt number of the suite. This value is zero-based, so the first attempt is `0`, +the second attempt is `1`, and so on. This property is useful in conjunction with the +`--test-rerun-failures` option to determine the attempt number of the current run. ### `context.diagnostic(message)`