Skip to content

Commit 0370563

Browse files
meyfaRafaelGSS
authored andcommitted
doc: fix heading levels for test runner hooks
before/after/beforeEach/afterEach are exported directly from `node:test` and should not be indented under `it.todo`. PR-URL: #44603 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
1 parent 6c55734 commit 0370563

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

doc/api/test.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -475,7 +475,7 @@ same as [`it([name], { skip: true }[, fn])`][it options].
475475
Shorthand for marking a test as `TODO`,
476476
same as [`it([name], { todo: true }[, fn])`][it options].
477477

478-
### `before([, fn][, options])`
478+
## `before([, fn][, options])`
479479

480480
<!-- YAML
481481
added: v18.8.0
@@ -503,7 +503,7 @@ describe('tests', async () => {
503503
});
504504
```
505505

506-
### `after([, fn][, options])`
506+
## `after([, fn][, options])`
507507

508508
<!-- YAML
509509
added: v18.8.0
@@ -531,7 +531,7 @@ describe('tests', async () => {
531531
});
532532
```
533533

534-
### `beforeEach([, fn][, options])`
534+
## `beforeEach([, fn][, options])`
535535

536536
<!-- YAML
537537
added: v18.8.0
@@ -560,7 +560,7 @@ describe('tests', async () => {
560560
});
561561
```
562562

563-
### `afterEach([, fn][, options])`
563+
## `afterEach([, fn][, options])`
564564

565565
<!-- YAML
566566
added: v18.8.0

0 commit comments

Comments
 (0)