Skip to content

Commit e53a925

Browse files
LiviaMedeirosjuanarbol
authored andcommitted
doc: fix example in assert.md
PR-URL: #42786 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Beth Griggs <bgriggs@redhat.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com> Reviewed-By: Akhil Marsonya <akhil.marsonya27@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Mestery <mestery@protonmail.com> Reviewed-By: Harshitha K P <harshitha014@gmail.com> Reviewed-By: Darshan Sen <raisinten@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent 3591ec7 commit e53a925

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

doc/api/assert.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -2137,7 +2137,7 @@ assert.throws(
21372137
);
21382138

21392139
// Using regular expressions to validate error properties:
2140-
throws(
2140+
assert.throws(
21412141
() => {
21422142
throw err;
21432143
},
@@ -2161,7 +2161,7 @@ throws(
21612161
);
21622162

21632163
// Fails due to the different `message` and `name` properties:
2164-
throws(
2164+
assert.throws(
21652165
() => {
21662166
const otherErr = new Error('Not found');
21672167
// Copy all enumerable properties from `err` to `otherErr`.
@@ -2206,7 +2206,7 @@ assert.throws(
22062206
);
22072207

22082208
// Using regular expressions to validate error properties:
2209-
throws(
2209+
assert.throws(
22102210
() => {
22112211
throw err;
22122212
},
@@ -2230,7 +2230,7 @@ throws(
22302230
);
22312231

22322232
// Fails due to the different `message` and `name` properties:
2233-
throws(
2233+
assert.throws(
22342234
() => {
22352235
const otherErr = new Error('Not found');
22362236
// Copy all enumerable properties from `err` to `otherErr`.

0 commit comments

Comments
 (0)