Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
doc: fix example in assert.md
  • Loading branch information
LiviaMedeiros committed Apr 19, 2022
commit 10313b3d7d96f435bff7696a8c82541dd7e3d2f1
8 changes: 4 additions & 4 deletions doc/api/assert.md
Original file line number Diff line number Diff line change
Expand Up @@ -2155,7 +2155,7 @@ assert.throws(
);

// Using regular expressions to validate error properties:
throws(
assert.throws(
() => {
throw err;
},
Expand All @@ -2179,7 +2179,7 @@ throws(
);

// Fails due to the different `message` and `name` properties:
throws(
assert.throws(
() => {
const otherErr = new Error('Not found');
// Copy all enumerable properties from `err` to `otherErr`.
Expand Down Expand Up @@ -2224,7 +2224,7 @@ assert.throws(
);

// Using regular expressions to validate error properties:
throws(
assert.throws(
() => {
throw err;
},
Expand All @@ -2248,7 +2248,7 @@ throws(
);

// Fails due to the different `message` and `name` properties:
throws(
assert.throws(
() => {
const otherErr = new Error('Not found');
// Copy all enumerable properties from `err` to `otherErr`.
Expand Down