From d834ac5c530332354a8688cacdfb055f9e9f7f99 Mon Sep 17 00:00:00 2001 From: cjihrig Date: Thu, 14 Mar 2024 17:20:06 -0400 Subject: [PATCH] test_runner: remove redundant report call This commit removes a redundant call to `reportStarted()`. It is redundant because a few lines down, `subtest.finalize()` is called. `finalize()` will find the first test that is ready to report its data, and then call `report()`, which also calls `reportStarted()`. This will trigger the `'test:start'` as high up the test tree as necessary. --- lib/internal/test_runner/test.js | 4 ---- 1 file changed, 4 deletions(-) diff --git a/lib/internal/test_runner/test.js b/lib/internal/test_runner/test.js index 1642cfdd15e3c6..8926f8baa629c5 100644 --- a/lib/internal/test_runner/test.js +++ b/lib/internal/test_runner/test.js @@ -469,10 +469,6 @@ class Test extends AsyncResource { return; } - if (i === 1 && this.parent !== null) { - this.reportStarted(); - } - // Report the subtest's results and remove it from the ready map. subtest.finalize(); this.readySubtests.delete(i);