Question · JavaScript and React course · Module 13: Testing React
waitFor function in RTL
What does the waitFor function do in React Testing Library?
Answer options
- It waits for all CSS animations on the page to finish
- It repeats the assertion until it passes or the timeout runs out
- It blocks the component's rendering until a condition is met
- It pauses the test for a given number of milliseconds
You can check the correct answer by solving this task in the CodeWorlds game.