Tests causing 'not wrapped in act(...)' warning
Closed this issue · 0 comments
JakeLo123 commented
Running the tests will output several 'not wrapped in act(...)' warnings.
Description
The warning is being triggered by some tests calling testing-library's render
method with await
as well as some instances from within act
. This is an indication that react state of components being tested may be out of sync with assertions made in tests, which could cause unexpected behavior.
Relevant documentation
- https://testing-library.com/docs/react-testing-library/api/#act
- https://testing-library.com/docs/react-testing-library/api/#render
Community guidelines
All issues filed in this repository must abide by the FusionAuth community guidelines.