Jest: jest is not recognized as an internal or external command

Created on 10 Feb 2016  路  4Comments  路  Source: facebook/jest

npm install jest-cli --save-dev

Then when I run npm test, I got jest is not recognized as an internal or external command on Windows 10.

Thanks

Most helpful comment

I don't really know how npm works on windows but npm install jest-cli should create a symlink in node_modules/.bin/jest that you can use to run your scripts. If this doesn't work, your setup might be broken.

This issue seems unrelated to Jest, so I'm going to close it.

All 4 comments

Can you paste your package.json?

{
"name": "reactdemo",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "jest"
},
"author": "",
"license": "ISC",
"dependencies": {
"babel-preset-react": "^6.5.0",
"babelify": "^7.2.0",
"express": "^4.13.4",
"react": "^0.14.7",
"react-dom": "^0.14.7"
},
"devDependencies": {
"jest-cli": "^0.8.2"
}
}

Thank you!
Gary

I don't really know how npm works on windows but npm install jest-cli should create a symlink in node_modules/.bin/jest that you can use to run your scripts. If this doesn't work, your setup might be broken.

This issue seems unrelated to Jest, so I'm going to close it.

Eu realmente n茫o sei como o npm funciona nas janelas, mas deve criar um simelo em que voc锚 pode usar para executar seus scripts. Se isso n茫o funcionar, sua configura莽茫o pode estar quebrada.npm install jest-cli``node_modules/.bin/jest

Este problema n茫o tem rela莽茫o com jest, ent茫o eu vou fech谩-lo.

How to solve this problem? I've tried to put jest as an environment variable and it didn't work.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pfftdammitchris picture pfftdammitchris  路  76Comments

SimenB picture SimenB  路  131Comments

bookman25 picture bookman25  路  79Comments

calebmer picture calebmer  路  72Comments

benmonro picture benmonro  路  119Comments