Skip to content

Commit

Permalink
test: add Symbol test for assert.deepEqual()
Browse files Browse the repository at this point in the history
The existing test never ran because typeof Symbol === 'function' and not
'symbol'. We have Symbols now so remove the check and just run the test.

PR-URL: #3327
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
Trott authored and jasnell committed Oct 26, 2015
1 parent 287e830 commit 6305d26
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions test/parallel/test-assert.js
Original file line number Diff line number Diff line change
Expand Up @@ -140,9 +140,7 @@ assert.throws(makeBlock(a.deepEqual, 'a', ['a']), a.AssertionError);
assert.throws(makeBlock(a.deepEqual, 'a', {0: 'a'}), a.AssertionError);
assert.throws(makeBlock(a.deepEqual, 1, {}), a.AssertionError);
assert.throws(makeBlock(a.deepEqual, true, {}), a.AssertionError);
if (typeof Symbol === 'symbol') {
assert.throws(makeBlock(assert.deepEqual, Symbol(), {}), a.AssertionError);
}
assert.throws(makeBlock(a.deepEqual, Symbol(), {}), a.AssertionError);

// primitive wrappers and object
assert.doesNotThrow(makeBlock(a.deepEqual, new String('a'), ['a']),
Expand Down

0 comments on commit 6305d26

Please sign in to comment.