From c771d66864f7608063969a681b27b9727df2d7de Mon Sep 17 00:00:00 2001 From: Richie McColl Date: Fri, 10 Feb 2023 11:46:24 +0000 Subject: [PATCH] doc: fix test runner examples PR-URL: https://github.com/nodejs/node/pull/46565 Reviewed-By: Colin Ihrig Reviewed-By: Moshe Atlow Reviewed-By: Paolo Insogna Reviewed-By: Luigi Pinca Reviewed-By: Benjamin Gruenbaum --- doc/api/test.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/api/test.md b/doc/api/test.md index d93d0723297bdc..e3eca690246969 100644 --- a/doc/api/test.md +++ b/doc/api/test.md @@ -912,7 +912,7 @@ before each subtest of the current suite. ```js describe('tests', async () => { - beforeEach(() => t.diagnostic('about to run a test')); + beforeEach(() => console.log('about to run a test')); it('is a subtest', () => { assert.ok('some relevant assertion here'); }); @@ -943,7 +943,7 @@ after each subtest of the current test. ```js describe('tests', async () => { - afterEach(() => t.diagnostic('about to run a test')); + afterEach(() => console.log('finished running a test')); it('is a subtest', () => { assert.ok('some relevant assertion here'); });