Closed
Description
Version
v21.7.3
Platform
No response
Subsystem
No response
What steps will reproduce the bug?
A failing deepEqual
or deepStrictEqual
assertion in a test, when using the spec
test reporter.
How often does it reproduce? Is there a required condition?
No response
What is the expected behavior? Why is that the expected behavior?
The full diff, or at least a larger print depth, of the actual/expected objects helps debug the failing tests.
What do you see instead?
$> node --test 'test/**/*.test.js'
AssertionError [ERR_ASSERTION]: parse: /* A comment */ a
at <project-path>//test/testcases.test.js:34:14
at Array.forEach (<anonymous>)
at test.objectPrintDepth (<project-path>/test/testcases.test.js:20:45)
at async Test.run (node:internal/test_runner/test:640:9)
at async startSubtest (node:internal/test_runner/harness:218:3) {
generatedMessage: false,
code: 'ERR_ASSERTION',
actual: { type: 'SelectorList', selectors: [ [Object] ] },
expected: { type: 'SelectorList', selectors: [ [Object] ] },
operator: 'deepStrictEqual'
}
Additional information
Related to: #47051