Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/node.js/40.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Node.js 在使用mocha chai工作服运行单元测试时,如何忽略包含在(工作服)中的文件夹_Node.js_Mocha.js_Chai_Coveralls_Nyc - Fatal编程技术网

Node.js 在使用mocha chai工作服运行单元测试时,如何忽略包含在(工作服)中的文件夹

Node.js 在使用mocha chai工作服运行单元测试时,如何忽略包含在(工作服)中的文件夹,node.js,mocha.js,chai,coveralls,nyc,Node.js,Mocha.js,Chai,Coveralls,Nyc,嗨,我正试图将given排除在我的测试范围之外 下面是我的测试命令 "test": "nyc --reporter=html --reporter=text mocha --timeout 10000 --require @babel/register \"./{,!(node_modules)/**/}*.test.js\" --exit", 我唯一能做的就是避免mocha运行模块内置测试可能的重复我没有使用伊斯坦布尔我使用工作服来获得我的测试代码覆盖率-mocha-chai-covera

嗨,我正试图将given排除在我的测试范围之外 下面是我的测试命令

 "test": "nyc --reporter=html --reporter=text mocha --timeout 10000 --require @babel/register \"./{,!(node_modules)/**/}*.test.js\" --exit",

我唯一能做的就是避免mocha运行模块内置测试

可能的重复我没有使用伊斯坦布尔我使用工作服来获得我的测试代码覆盖率-mocha-chai-coverall-nyc
nyc
=伊斯坦布尔(我知道这很混乱)是产生覆盖率的原因。工作服就是展示你的覆盖范围的地方。您是否尝试过从可能重复的链接中获取解决方案?