Skip to content

Commit

Permalink
test: add test for assert.notStrictEqual()
Browse files Browse the repository at this point in the history
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 <mic.besace@gmail.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: cjihrig - Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: jasnell - James M Snell <jasnell@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
  • Loading branch information
Trott authored and MylesBorins committed Oct 26, 2016
1 parent ea72e9f commit c9af24d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/parallel/test-assert.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ assert.throws(makeBlock(a.strictEqual, 2, '2'),
assert.throws(makeBlock(a.strictEqual, null, undefined),
a.AssertionError, 'strictEqual(null, undefined)');

assert.throws(makeBlock(a.notStrictEqual, 2, 2),
a.AssertionError, 'notStrictEqual(2, 2)');

assert.doesNotThrow(makeBlock(a.notStrictEqual, 2, '2'),
'notStrictEqual(2, \'2\')');

Expand Down

0 comments on commit c9af24d

Please sign in to comment.