cypress-io / cypress Public
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cypress-cli type for CypressRunResult::runs is incorrect (can be null/undefined) #6126
Comments
Following the instructions within the
As previously mentioned and from my understanding, there are currently a couple of ways of solving this:
Option 2 sounds like the long term solution. I think changes will be around the lines of https://github.com/cypress-io/cypress/blob/develop/packages/server/lib/plugins/util.coffee#L37 however it seems like we would need to distinguish Can I help with with 2, with the short term solution 1, or with any other suggested solution? |
@ddayguerrero Yes we would love an open PR - even one that is a work in progress is fine. Check out our contributing doc and ask us if you get stuck. |
@jennifer-shehane my PR is ready for final review... |
The code for this is done in cypress-io/cypress#6127, but has yet to be released. |
Released in This comment thread has been locked. If you are still experiencing this issue after upgrading to |
Current behavior:
In the event that the browser fails to connect, the run promise resolves with results which has
runs
ofnull
orundefined
. (Which is likely a separate issue altogether. It should probably not resolve at all - it should reject).However, the typings indicate that the type of
runs
isRunResult[]
which doesn't matchnull
Desired behavior:
The type should indicate that
runs
can be undefined or null, orrun()
should not resolve on an error running the tests altogether.Test code to reproduce
npm i && npm test
The text was updated successfully, but these errors were encountered: