Testing · Junior · Question 50 of 78

What is better for simulating user actions: fireEvent or user-event?

Explanation

fireEvent.click dispatches one event. userEvent.click also moves the pointer, focuses and respects disabled and pointer-events.

Further reading

Problem with a question

Testing · Junior · question 50

Test yourself

Take the Testing · Junior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz