1×
Become a member
to unlock all features

Level Up!

Access all courses & lessons on egghead today and lock-in your price for life.

Autoplay

    Fix the "not wrapped in act(...)" warning with Jest fake timers

    reactReact

    There aren't many places you need to manually use act if you're using React Testing Library's async utilities, but if you're using fake timers, you need to manually use act to avoid missing bugs in your code.

    In this lesson you'll learn how to identify the cause of act warnings and how to resolve them.

    This is based on my blog post: Fix the "not wrapped in act(...)" warning