Open KevinEonix opened 4 months ago
This might be a configuration issue. The act
warnings are handled by the wrappers brought by @testing-library/react
.
Please try to remove unnecessary calls and config entries like https://github.com/KevinEonix/DevExpressVitestError/blob/13404333f4fc9aa8d5935520a9ae4fea98a033e9/src/FormForTest/FormForTest.test.tsx#L6-L8 https://github.com/KevinEonix/DevExpressVitestError/blob/13404333f4fc9aa8d5935520a9ae4fea98a033e9/vite.config.ts#L32
If the problem persists, please try to reduce the reproduction to a minimal example that still displays the issue – preferably without third-party libraries like react-hook-forms.
I tried without the configs and the cleanup
call but unfortunately, i have the same issue.
See the test-without-rhf branch
Reproduction example
https://github.com/KevinEonix/DevExpressVitestError
Prerequisites
FormForTest
Expected behavior
not returning the warning for act
Actual behavior
It return an act warning when awaiting the call to userEvent
User-event version
14.5.2
Environment
Testing Library framework:
JS framework:
react@18.2.0
Test environment:
DOM implementation: jsdom@24.0.0
Additional context
Here is the link to the repository https://github.com/KevinEonix/DevExpressVitestError