-
Notifications
You must be signed in to change notification settings - Fork 470
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
queryByText failing when querying a component that returns a string #50
Comments
Full call stack,
The most interesting part:
|
This appears to be an issue with jest-dom and not dom-testing-library. Perhaps there could be some more helpful error messages here. Please file an issue there! Thanks! |
Coincidentally this was being worked on and fixed in testing-library/jest-dom#15 but the build on travis is failing and I'm working on it so it's not released yet. |
This should be fixed now in |
…ary#50) * Added React TDD examples with react-testing-library * Added React TDD examples with react-testing-library * Resolved conflicts
I got the same error, but the way I got this is dark magic. It was working while I was writing tests, and then all of a sudden it broken everything. |
dom-testing-library
version: 2.4.0react
version: 16.3.2Relevant code or config:
What you did:
I ran the test.
What happened:
It returned an error:
Reproduction:
https://codesandbox.io/s/j4rkx7jmlv
Problem description:
I expect
queryByText()
to work with components that return a string.Suggested solution:
Improve
queryByText()
so it supports components that return a string.The text was updated successfully, but these errors were encountered: