-
-
Notifications
You must be signed in to change notification settings - Fork 33.5k
Closed
Labels
assertIssues and PRs related to the assert subsystem.Issues and PRs related to the assert subsystem.docIssues and PRs related to the documentations.Issues and PRs related to the documentations.
Description
deepStrictEqual()
description currently begins with:
Generally identical to
assert.deepEqual()
with the exception that primitive
values are compared using the strict equality operator (===
).
But, deepStrictEqual()
also compares prototype equality. Example (v5.6.0
):
var assert = require("assert");
var a = [0];
var b = {0: 0};
["deepEqual", "deepStrictEqual"].forEach(function (meth) {
assert[meth](a, b, "not " + meth);
});
// AssertionError: not deepStrictEqual
Metadata
Metadata
Assignees
Labels
assertIssues and PRs related to the assert subsystem.Issues and PRs related to the assert subsystem.docIssues and PRs related to the documentations.Issues and PRs related to the documentations.