-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
findBy* and waitForElement* not returning HTMLElement anymore (since 6.1.0) (works in dom-testing-library) #345
Comments
I've reproduced this. I'm working on a fix |
in act-compat seems to fix it for me |
That's what I was thinking as well, but it's not working for me 🤔 |
Let me open a quick PR to check. |
Interestingly, that fixes |
Oh, nevermind. That was something else. I'll have this fixed in a moment. |
I'll just push to master and consider your feedback a review 😉 |
Oh! Interesting indeed, ya okay I'll close my PR then. |
Oh, I didn't notice you made one! I'll merge yours! |
🎉 This issue has been resolved in version 6.1.2 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
…ary#345)" (testing-library#349) This reverts commit 6203cc7.
react-testing-library
version: 6.1.xreact
version: ^16.8.3node
version: 10.15.xnpm
(oryarn
) version: 6.9.0Relevant code or config:
The following test fails in react-testing-library
While the following test passes in dom-testing-library
What you did:
I was trying to use the
findByTestId
API to grab an element.What happened:
The resolved value is undefined in react-testing-library 6.1.x but returns fine in 6.0.0.
Reproduction:
See the above scenarios above.
Problem description:
Code that used to leverage the elements returned by findBy* and waitFor* will now start to fail.
Suggested solution:
I suspect this has to do with the recent asyncWrapper addition, which is set to
cb => cb()
in DTL but likely something that doesn't return the value in RTL.The text was updated successfully, but these errors were encountered: