Mocha-aure-reporter不使用节点js

当我用mocha-alure-reporter运行我的testing时,我遇到了问题,testing用mocha成功运行,但是mocha –reporter mocha-aure-reporter返回以下错误

> notifications-api@1.0.0 test /app > mocha --reporter mocha-allure-reporter 2016-11-15T06:13:26.762Z - info: Notification API up and running on port 4000 2016-11-15T06:13:26.773Z - error: Tue, 15 Nov 2016 06:13:26 GMT uncaughtException 2016-11-15T06:13:26.775Z - error: TypeError: test.currentRetry is not a function at Runner.<anonymous> (/app/node_modules/mocha-allure-reporter/index.js:29:19) at emitOne (events.js:77:13) at Runner.emit (events.js:169:7) at next (/app/node_modules/mocha/lib/runner.js:517:10) at Runner.runTests (/app/node_modules/mocha/lib/runner.js:556:3) at /app/node_modules/mocha/lib/runner.js:637:10 at next (/app/node_modules/mocha/lib/runner.js:283:14) at Immediate._onImmediate (/app/node_modules/mocha/lib/runner.js:319:5) at processImmediate [as _immediateCallback] (timers.js:383:17) npm ERR! Test failed. See above for more details. 

任何人都可以帮助解决这个问题?

       

网上收集的解决方案 "Mocha-aure-reporter不使用节点js"

这个问题可以通过更新你的摩卡到最新版本来解决,可能是v3或更高版本,也可以吸引记者。 如果问题仍然存在TypeError: test.currentRetry is not a function ,请replace代码行

 if (!test.currentRetry()) { 

与以下

 if (typeof test.currentRetry !== "function" || !test.currentRetry()) {