Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jest Tests complain about async tasks cleanup not present #1

Open
michaelryancaputo opened this issue Feb 19, 2019 · 0 comments
Open

Comments

@michaelryancaputo
Copy link

michaelryancaputo commented Feb 19, 2019

Hi! I found your article on upmostly. I found it very useful, however I'm trying to write a Jest test for this module using the react-testing-library. It seems like there is something that is not being cancelled. The error is this:

Warning: Can't perform a React state update on an unmounted component. This is a no-op, but it indicates a memory leak in your application. To fix, cancel all subscriptions and asynchronous tasks in a useEffect cleanup function.

I think it's complaining about the fetchMoreListItems function not being cancelable.

Any thoughts on this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant