-
Notifications
You must be signed in to change notification settings - Fork 150
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
Update documentation with issues using react-test-renderer #250
Comments
Enzmye based test:
|
@mrchief does the shallow rendering from the Enzyme based test work? |
Yes, no issues with Enzyme. I'm still using the polyfill though. Let me know if you want me to try without the polyfill. |
jamesmfriedman
pushed a commit
that referenced
this issue
Jul 11, 2018
Updated the docs accordingly, will be released with 1.8 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Creating this issue as per our discussion on gitter.
react-test-renderer doesn't support refs based components for testing. See:
facebook/react/issues/9244
facebook/jest/issues/1805
facebook/jest/issues/5462
The workarounds are:
Mock 3rd party components
E.g.
Use something like
createNodeMock
See https://reactjs.org/docs/test-renderer.html#ideas (source)
Use ReactDOM or Enzyme
See facebook/jest/issues/5462#issuecomment-363532494
The text was updated successfully, but these errors were encountered: