percyhanna / chai-react

Chai assertions for React
MIT License
40 stars 3 forks source link

Make compatible with React 16 #17

Closed valscion closed 5 years ago

valscion commented 5 years ago

This PR makes chai-react compatible with React 16. The test file passes when ran in browser.

Old description hidden below This might allow React 16 to still work with this package. The `react-addons-test-utils` package has been deprecated and one should use `react-dom/test-utils` instead: https://reactjs.org/blog/2017/09/26/react-v16.0.html#packaging This change allows us to remove `react-addons-test-utils` from our repository altogether while legacy tests still using `chai-react` pass now. Let me know if I can help you with getting this to some release :relaxed: EDIT: Unfortunately it seems this isn't enough to make `chai-react` compatible with React 16. Oh well. I'll see if there's a way to make this compatible with React 16, or if it would be easier to migrate tests away from `chai-react` altogether
percyhanna commented 5 years ago

Would you need to update package.json as well? I'm happy to help out a little if needed, but this repository is mostly inactive these days.

valscion commented 5 years ago

I'll see if I can get this to work with React 16, as that's the next thing on my plate. I'll let you know how it goes.

valscion commented 5 years ago

Ok now the CI passes, too. I think this should be good to go :relaxed:. This could be releases as 4.0.0, as it is a breaking change to support only React 16 and forward

percyhanna commented 5 years ago

Should be published as version 4.0.0 now.

valscion commented 5 years ago

Thanks! I'll give it a go the next time I touch code related to this ☺️