Skip to content

Commit

Permalink
test_runner: remove plan option from run()
Browse files Browse the repository at this point in the history
This commit removes the plan option to run(). I believe it was
added by mistake. It is not documented, untested, and a test
plan does not make sense in the context of run().

This commit also fixes a minor formatting issue in a related
fixture.

Refs: #52860
PR-URL: #53834
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
  • Loading branch information
cjihrig authored and marco-ippolito committed Aug 19, 2024
1 parent 8660d48 commit 206c668
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions lib/internal/test_runner/runner.js
Original file line number Diff line number Diff line change
Expand Up @@ -524,7 +524,6 @@ function run(options) {
watch,
setup,
only,
plan,
} = options;

if (files != null) {
Expand Down Expand Up @@ -577,7 +576,7 @@ function run(options) {
});
}

const root = createTestTree({ __proto__: null, concurrency, timeout, signal, plan });
const root = createTestTree({ __proto__: null, concurrency, timeout, signal });
root.harness.shouldColorizeTestFiles ||= shouldColorizeTestFiles(root);

if (process.env.NODE_TEST_CONTEXT !== undefined) {
Expand Down
2 changes: 1 addition & 1 deletion test/fixtures/test-runner/output/test-runner-plan.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,6 @@ test('planning with streams', (t, done) => {
});

stream.on('end', () => {
done();
done();
});
})

0 comments on commit 206c668

Please sign in to comment.