Closed seanpoulter closed 5 months ago
I wonder how the Cucumber execution differs from e.g. Mocha that causes this problem is the first place 🤔
Let me know if you want me to dig into it.
I think we can move forward with the patch #116 .. it's not to crucial for me to get to the bottom of this as long as we document what we are doing in #116 so everyone knows.
Problem
When I use @wdio/cucumber-framework to run my tests Then I see an unexpected
Error: Connection closed. Code: 1006
Steps to Reproduce
I've reproduced the error from a private repo in https://github.com/seanpoulter/wdio-vscode-cucumber-example:
Analysis
The error is thrown from line 60 https://github.com/webdriverio-community/wdio-vscode-service/blob/92b7b6b8ba8def19eb446cae7a1f9107150caffb/src/service.ts#L58-L62
which is registered on line 116
https://github.com/webdriverio-community/wdio-vscode-service/blob/92b7b6b8ba8def19eb446cae7a1f9107150caffb/src/service.ts#L110-L117
Questions
this._promisedSocket
is assigned inbeforeSession
hook, does it make sense to use thedeleteSession
hook to resetthis._promisedSocket = undefined
?