-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Closed
Labels
pkg/runnerThis is due to an issue in the packages/runner directoryThis is due to an issue in the packages/runner directorytype: bug
Description
Current behavior
There are currently two issues with bigint in cypress.
- when it prints log output, it says
{}instead of serializing the bigint. If you click on the assertion, it displays properly in the console:

- If either the expected or actual value is
0n, you get an exception when you click on it:

Desired behavior
- Bigints assertions should display their values in the command log (possibly with truncation)
- if you click on a bigint assertion that has
0non expected or actual, no exception should occur
Test code to reproduce
describe('Bigint example', () => {
it('Displays wrong', () => {
expect(2n).to.equal(2n);
});
it('Exception on inspect', () => {
expect(1n).to.equal(0n);
})
it('Exception on inspect 2', () => {
expect(0n).to.equal(1n);
})
});Versions
This is present in 5.6.0 through 7.3.0, though you get different behavior for the exception in 5.6.0 and 7.3.0. In older versions, it doesn't show the exception and stack trace, but expected/actual are missing:


Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
pkg/runnerThis is due to an issue in the packages/runner directoryThis is due to an issue in the packages/runner directorytype: bug