Skip to content

Commit c9af24d

Browse files
TrottMylesBorins
authored andcommitted
test: add test for assert.notStrictEqual()
There is currently no test for `assert.notStrictEqual()` throwing an `AssertionError` when passed identical values. This change adds such a test. PR-URL: #8091 Reviewed-By: targos - Michaël Zasso <[email protected]> Reviewed-By: Franziska Hinkelmann <[email protected]> Reviewed-By: cjihrig - Colin Ihrig <[email protected]> Reviewed-By: jasnell - James M Snell <[email protected]> Reviewed-By: Santiago Gimeno <[email protected]>
1 parent ea72e9f commit c9af24d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

test/parallel/test-assert.js

+3
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,9 @@ assert.throws(makeBlock(a.strictEqual, 2, '2'),
5555
assert.throws(makeBlock(a.strictEqual, null, undefined),
5656
a.AssertionError, 'strictEqual(null, undefined)');
5757

58+
assert.throws(makeBlock(a.notStrictEqual, 2, 2),
59+
a.AssertionError, 'notStrictEqual(2, 2)');
60+
5861
assert.doesNotThrow(makeBlock(a.notStrictEqual, 2, '2'),
5962
'notStrictEqual(2, \'2\')');
6063

0 commit comments

Comments
 (0)