webdriverio-boneyard / wdio-mocha-framework

A WebdriverIO v4 plugin. Adapter for Mocha testing framework.
MIT License
39 stars 30 forks source link

The whole test suite is failed when beforeEach hook is failed #154

Open sanyco92 opened 5 years ago

sanyco92 commented 5 years ago

Hello, I'm facing a similar issue as described in https://github.com/mochajs/mocha/pull/1014 thread. I have a test suite with 100+ scenarios, and also I have beforeEach hook. But sometimes something may go wrong and 'beforeEach' hook can be failed. I don't need to stop the whole test suite execution, instead, I need to continue execution of the following test scenarios. But it looks like mocha just exits and test execution is stopped. I tried the solution from https://github.com/mochajs/mocha/pull/1014, changed some parts of the code and it works as I need. Could someone add this fix to wdio-mocha-framework? Thanks!