Skip to content

Commit c76d182

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 <[email protected]> Reviewed-By: Antoine du Hamel <[email protected]> Reviewed-By: Mohammed Keyvanzadeh <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
1 parent 4d6b46e commit c76d182

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
@@ -480,7 +480,7 @@ same as [`it([name], { skip: true }[, fn])`][it options].
480480
Shorthand for marking a test as `TODO`,
481481
same as [`it([name], { todo: true }[, fn])`][it options].
482482

483-
### `before([, fn][, options])`
483+
## `before([, fn][, options])`
484484

485485
<!-- YAML
486486
added: v18.8.0
@@ -508,7 +508,7 @@ describe('tests', async () => {
508508
});
509509
```
510510

511-
### `after([, fn][, options])`
511+
## `after([, fn][, options])`
512512

513513
<!-- YAML
514514
added: v18.8.0
@@ -536,7 +536,7 @@ describe('tests', async () => {
536536
});
537537
```
538538

539-
### `beforeEach([, fn][, options])`
539+
## `beforeEach([, fn][, options])`
540540

541541
<!-- YAML
542542
added: v18.8.0
@@ -565,7 +565,7 @@ describe('tests', async () => {
565565
});
566566
```
567567

568-
### `afterEach([, fn][, options])`
568+
## `afterEach([, fn][, options])`
569569

570570
<!-- YAML
571571
added: v18.8.0

0 commit comments

Comments
 (0)