Skip to content
Closed
Changes from 1 commit
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
Prev Previous commit
Next Next commit
fixup: address comments
  • Loading branch information
BridgeAR committed Apr 26, 2018
commit 2da7521b4e808b829496c5023a45b2b575660741
8 changes: 4 additions & 4 deletions doc/api/assert.md
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ weakMap3.unequal = true;
assert.deepStrictEqual(weakMap1, weakMap2);
// OK, because it is impossible to compare the entries

// Fail because weakMap3 has a property that weakMap1 does not contain:
// Fails because weakMap3 has a property that weakMap1 does not contain:
assert.deepStrictEqual(weakMap1, weakMap3);
// AssertionError: Input A expected to strictly deep-equal input B:
// + expected - actual
Expand Down Expand Up @@ -666,8 +666,8 @@ changes:

Throws `value` if `value` is not `undefined` or `null`. This is useful when
testing the `error` argument in callbacks. The stack trace contains all frames
from the error passed to `ifError` including the potential new frames for
`ifError` itself. See below for an example.
from the error passed to `ifError()` including the potential new frames for
`ifError()` itself. See below for an example.

```js
const assert = require('assert').strict;
Expand Down Expand Up @@ -921,7 +921,7 @@ assert.ok(1);
// OK

assert.ok();
// AssertionError: No value argument passed to `assert.ok`.
// AssertionError: No value argument passed to `assert.ok()`.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FWIW, there's no period at the end of the error message:

> assert.ok()
AssertionError [ERR_ASSERTION]: No value argument passed to `assert.ok()`
> 


assert.ok(false, 'it\'s false');
// AssertionError: it's false"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: remove "

Expand Down