Explore Library
Quiz

Async Assertions After Mocked Fetch

Choosing the right async assertion approach when testing components that fetch data.

You mock an API and render a component that fetches a user's name and displays it after the promise resolves. Which is the most robust way to assert the name eventually appears?