Skip to content
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

Fix 'react-test-renderer/package' not found #2048

Merged
merged 1 commit into from Mar 13, 2019

Conversation

Projects
None yet
5 participants
@zombieJ
Copy link
Contributor

zombieJ commented Mar 13, 2019

Latest version of 1.11.0 throw error:

Cannot find module 'react-test-renderer/package' from 'ReactSixteenAdapter.js'

Fixes #2046

[enzyme-adapter-react-16] [fix] add an explicit `.json` extension
Some folks with broken jest configurations were seeing "'react-test-renderer/package' not found".

Fixes #2046
@zombieJ

This comment has been minimized.

Copy link
Contributor Author

zombieJ commented Mar 13, 2019

@ljharb please help to check this.

@ljharb

ljharb approved these changes Mar 13, 2019

Copy link
Member

ljharb left a comment

Thanks.

@ljharb ljharb merged commit 9b964a8 into airbnb:master Mar 13, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

ljharb added a commit that referenced this pull request Mar 13, 2019

[enzyme-adapter-react-16] v1.11.1
 - [fix] add an explicit `.json` extension (#2048, #2046)

@zombieJ zombieJ deleted the zombieJ:patch-1 branch Mar 14, 2019

@afc163

This comment has been minimized.

Copy link

afc163 commented Mar 14, 2019

https://www.npmjs.com/package/enzyme-adapter-react-16 1.11.1 is still not released in npm.

@ljharb

This comment has been minimized.

Copy link
Member

ljharb commented Mar 14, 2019

it is now.

@ramchoudhary

This comment has been minimized.

Copy link

ramchoudhary commented on 9b964a8 Mar 14, 2019

Hi @ljharb ,
Since yesterday, I'm getting "Cannot find module 'react-test-renderer/package' from 'ReactSixteenAdapter.js'" error in my bamboo build. It's working fine in local and it was working fine previously in bamboo as well. Do you think this change might have something to do with this?
Can you please have a look.
I'm using -
"react": "^16.6.3",
"react-dom": "^16.6.3",
"enzyme-adapter-react-16": "^1.7.1",
"react-test-renderer": "^16.2.0",

This comment has been minimized.

Copy link
Member

ljharb replied Mar 14, 2019

@ramchoudhary this is fixed in v1.11.1, but it only broke for people using jest, with an invalid moduleFileExtensions (that omits json). Please file an issue if that's not the case for you.

This comment has been minimized.

Copy link

ramchoudhary replied Mar 14, 2019

@ljharb I'm using jest only with enzyme.

This comment has been minimized.

Copy link
Member

ljharb replied Mar 14, 2019

then check your jest config; either way, i should be fixed in v1.11.1.

This comment has been minimized.

Copy link

ramchoudhary replied Mar 14, 2019

Yeah mate! Just upgraded to v1.11.1 from v1.7.1 and now it working fine.
Thanks a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.