react icon indicating copy to clipboard operation
react copied to clipboard

npm test failed for ReactTestRenderer-test.js

Open pinakdas163 opened this issue 9 years ago • 3 comments

Do you want to request a feature or report a bug?

I want to request a bug

What is the current behavior? After cloning React and installing dependencies, when I ran npm test. I found one test suites to failed out 126.

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via https://jsfiddle.net or similar (template: https://jsfiddle.net/reactjs/69z2wepo/).

run command: npm test

What is the expected behavior?

FAIL src/renderers/testing/tests/ReactTestRenderer-test.js Test suite failed to run Cannot find module 'pretty-format' from 'ReactTestRenderer-test.js'

Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React? v15.4.2

pinakdas163 avatar Feb 18 '17 09:02 pinakdas163

Seems that you didn't have pretty-format installed.Can you see it in your node_modules directory?

jddxf avatar Feb 18 '17 13:02 jddxf

I checked pretty-format module is not installed in the node_modules directory. I tried to install it, but I get this error. Any suggestion how to fix it?

npm install pretty-format --save npm ERR! Linux 4.4.0-62-generic npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "pretty-format" "--save" npm ERR! node v4.7.3 npm ERR! npm v2.15.11 npm ERR! code EPEERINVALID

npm ERR! peerinvalid The package [email protected] does not satisfy its siblings' peerDependencies requirements! npm ERR! peerinvalid Peer [email protected] wants babel-eslint@^6.1.2

pinakdas163 avatar Feb 18 '17 17:02 pinakdas163

I am closing this issue as the initial error that I got was fixed

pinakdas163 avatar Feb 22 '17 06:02 pinakdas163