Skip to content

Differences are vanished in error output message #95

@bence-balogh-intland

Description

@bence-balogh-intland

Hi guys,
Please consider the following test case:

    it.only('should whatever', () => {
        const result$ = cold('-a--|', {
            a: { prop: NaN }
        });

        const expectedResult$ = cold('-a--|', {
            a: { prop: null }
        });

        expect(result$).toBeObservable(expectedResult$);
    });

The 2 prop obviously differs, so the test case will fail.
Unfortunately, the difference is vanished from the output message, since during stringification of frames, NaN becomes null:
image

The differences should be highlighted as follows:
image

Could you please check?

Thanks,
Bence

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions