-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
[enzyme-adapter-react-{16,16.3}] [fix] forwardRef
: respect .displayName
#1817
Conversation
…yName` on the forwardRef Fixes #1810.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it worth testing the .find()
behaviour as seen in the original ticket
Out of curiosity, why are 16.1 and 16.2 adapters missing a bunch of special cases in displayNameOfNode
that exist in 16.0 or 16.3 (https://github.com/airbnb/enzyme/blob/master/packages/enzyme-adapter-react-16/src/ReactSixteenAdapter.js#L442 vs https://github.com/airbnb/enzyme/blob/master/packages/enzyme-adapter-react-16.1/src/ReactSixteenOneAdapter.js#L420)?
@jgzuke because the 16 adapter is for 16.0 - 16.5, but the 16.3 adapter is only for 16.3, and those special cases are only in 16.3+. |
I don't think it's really worth it; the original issue's repro requires styled-components, but in general, if it shows up in |
dafe529
to
d2c06d9
Compare
Thanks Jordan! |
Hello there! Will it be released anytime soon? |
- [new] add `isCustomComponentElement` (#1832) - [fix] (<= v16.2) ensure that `this.state` starts out `null` when unspecified on a custom component (#1849) - [fix] `forwardRef`: respect `.displayName` on the forwardRef (#1817) - [deps] update `babel-preset-airbnb`, `chai`, `eslint`, `mocha`, `enzyme-adapter-utils`, `react-is`, `airbnb-js-shims`
Fixes #1810.