Skip to content

Commit 42413b6

Browse files
committed
doc: add changelogs for assert
PR-URL: #11489 Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Sam Roberts <[email protected]> Reviewed-By: Roman Reiss <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Italo A. Casas <[email protected]>
1 parent d9d541d commit 42413b6

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

doc/api/assert.md

+31
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,16 @@ assert(false, 'it\'s false');
3030
## assert.deepEqual(actual, expected[, message])
3131
<!-- YAML
3232
added: v0.1.21
33+
changes:
34+
- version: v6.4.0, v4.7.1
35+
pr-url: https://github.com/nodejs/node/pull/8002
36+
description: Typed array slices are handled correctly now.
37+
- version: v6.1.0, v4.5.0
38+
pr-url: https://github.com/nodejs/node/pull/6432
39+
description: Objects with circular references can be used as inputs now.
40+
- version: v5.10.1, v4.4.3
41+
pr-url: https://github.com/nodejs/node/pull/5910
42+
description: Handle non-`Uint8Array` typed arrays correctly.
3343
-->
3444

3545
Tests for deep equality between the `actual` and `expected` parameters.
@@ -91,6 +101,16 @@ parameter is undefined, a default error message is assigned.
91101
## assert.deepStrictEqual(actual, expected[, message])
92102
<!-- YAML
93103
added: v1.2.0
104+
changes:
105+
- version: v6.4.0, v4.7.1
106+
pr-url: https://github.com/nodejs/node/pull/8002
107+
description: Typed array slices are handled correctly now.
108+
- version: v6.1.0
109+
pr-url: https://github.com/nodejs/node/pull/6432
110+
description: Objects with circular references can be used as inputs now.
111+
- version: v5.10.1, v4.4.3
112+
pr-url: https://github.com/nodejs/node/pull/5910
113+
description: Handle non-`Uint8Array` typed arrays correctly.
94114
-->
95115

96116
Generally identical to `assert.deepEqual()` with two exceptions. First,
@@ -115,6 +135,13 @@ parameter is undefined, a default error message is assigned.
115135
## assert.doesNotThrow(block[, error][, message])
116136
<!-- YAML
117137
added: v0.1.21
138+
changes:
139+
- version: v5.11.0, v4.4.5
140+
pr-url: https://github.com/nodejs/node/pull/2407
141+
description: The `message` parameter is respected now.
142+
- version: v4.2.0
143+
pr-url: https://github.com/nodejs/node/pull/3276
144+
description: The `error` parameter can now be an arrow function.
118145
-->
119146

120147
Asserts that the function `block` does not throw an error. See
@@ -402,6 +429,10 @@ If the values are not strictly equal, an `AssertionError` is thrown with a
402429
## assert.throws(block[, error][, message])
403430
<!-- YAML
404431
added: v0.1.21
432+
changes:
433+
- version: v4.2.0
434+
pr-url: https://github.com/nodejs/node/pull/3276
435+
description: The `error` parameter can now be an arrow function.
405436
-->
406437

407438
Expects the function `block` to throw an error.

0 commit comments

Comments
 (0)