Skip to content

Not work test after update from 14.5.2 to 14.6.1 (toHaveValue('100 + 50')) #1303

@KalashnikovTV

Description

@KalashnikovTV

Prerequisites

`
it('should display a mathematical expression when operators are entered', async () => {
const mockOnChange = jest.fn();

    render(
        <CalculationInput
            onChange={mockOnChange}
            minorUnits={100}
            currency='RUR'
            dataTestId='calculation-input'
        />,
    );

    const input = await screen.findByRole('textbox');

    await userEvent.type(input, '100+50');

    await waitFor(() => {
        expect(input).toHaveValue('100 + 50');
    });
});
`

Expected: "100 + 50"
Received: "10 050"

Expected behavior

Expected: "100 + 50"

Actual behavior

Received: "10 050"

User-event version

14.6.1

Environment

Testing Library framework:

JS framework:

Test environment:

DOM implementation:

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingneeds assessmentThis needs to be looked at by a team member

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions