npm执行在Windows

时间:2017-06-19 06:13:39

标签: node.js npm

我有一个脚本来运行mocha中定义的package.json测试用例,如下所示:

...
'test':  mocha tests/integration/ --opts mocha.opts -t 20000
...

测试将持续约10分钟。此脚本在Mac和Linux中可以正常工作,但在Windows10中则不行。

在windows10上执行时,测试用例正在执行,但几分钟后,进程因以下错误消息而停止:

npm ERR! Windows_NT 10.0.15063
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "test:integration:win"
npm ERR! node v7.10.0
npm ERR! npm  v4.2.0
npm ERR! code ELIFECYCLE
npm ERR! errno 3221225725
npm ERR! mycontroller@0.1.4 test:integration:win: `mocha tests/integration/ --opts mocha.opts -t 20000`
npm ERR! Exit status 3221225725
npm ERR!

此消息与测试用例本身无关。我相信他们与环境有关。有谁知道这个问题?

这是nodejs后端应用程序。

0 个答案:

没有答案