Skip to content

Commit e26f736

Browse files
MoLowFyko
authored andcommitted
doc: fix typo in test runner code examples
PR-URL: nodejs#44351 Reviewed-By: Jacob Smith <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
1 parent 37a34f3 commit e26f736

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

doc/api/test.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,7 @@ before each subtest of the current suite.
528528

529529
```js
530530
describe('tests', async () => {
531-
beforeEach(() => t.diagnostics('about to run a test'));
531+
beforeEach(() => t.diagnostic('about to run a test'));
532532
it('is a subtest', () => {
533533
assert.ok('some relevant assertion here');
534534
});
@@ -557,7 +557,7 @@ after each subtest of the current test.
557557

558558
```js
559559
describe('tests', async () => {
560-
afterEach(() => t.diagnostics('about to run a test'));
560+
afterEach(() => t.diagnostic('about to run a test'));
561561
it('is a subtest', () => {
562562
assert.ok('some relevant assertion here');
563563
});
@@ -598,7 +598,7 @@ before each subtest of the current test.
598598

599599
```js
600600
test('top level test', async (t) => {
601-
t.beforeEach((t) => t.diagnostics(`about to run ${t.name}`));
601+
t.beforeEach((t) => t.diagnostic(`about to run ${t.name}`));
602602
await t.test(
603603
'This is a subtest',
604604
(t) => {
@@ -630,7 +630,7 @@ after each subtest of the current test.
630630

631631
```js
632632
test('top level test', async (t) => {
633-
t.afterEach((t) => t.diagnostics(`finished running ${t.name}`));
633+
t.afterEach((t) => t.diagnostic(`finished running ${t.name}`));
634634
await t.test(
635635
'This is a subtest',
636636
(t) => {

0 commit comments

Comments
 (0)