From eb90d650d4045f47d6cc2e2caaefe159ace3b3e5 Mon Sep 17 00:00:00 2001 From: Moshe Atlow Date: Tue, 23 Aug 2022 11:21:10 +0300 Subject: [PATCH] doc: fix typo in test runner code examples PR-URL: https://github.com/nodejs/node/pull/44351 Reviewed-By: Jacob Smith Reviewed-By: Luigi Pinca --- doc/api/test.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/api/test.md b/doc/api/test.md index 22c11e97a3357a..e955c6f1b2a9b1 100644 --- a/doc/api/test.md +++ b/doc/api/test.md @@ -524,7 +524,7 @@ before each subtest of the current suite. ```js describe('tests', async () => { - beforeEach(() => t.diagnostics('about to run a test')); + beforeEach(() => t.diagnostic('about to run a test')); it('is a subtest', () => { assert.ok('some relevant assertion here'); }); @@ -553,7 +553,7 @@ after each subtest of the current test. ```js describe('tests', async () => { - afterEach(() => t.diagnostics('about to run a test')); + afterEach(() => t.diagnostic('about to run a test')); it('is a subtest', () => { assert.ok('some relevant assertion here'); }); @@ -592,7 +592,7 @@ before each subtest of the current test. ```js test('top level test', async (t) => { - t.beforeEach((t) => t.diagnostics(`about to run ${t.name}`)); + t.beforeEach((t) => t.diagnostic(`about to run ${t.name}`)); await t.test( 'This is a subtest', (t) => { @@ -624,7 +624,7 @@ after each subtest of the current test. ```js test('top level test', async (t) => { - t.afterEach((t) => t.diagnostics(`finished running ${t.name}`)); + t.afterEach((t) => t.diagnostic(`finished running ${t.name}`)); await t.test( 'This is a subtest', (t) => {