WebSocket connection does not respect the throw
option
#2247
Labels
breaking change
for PRs that need to be mentioned in the breaking changes section of the release notes
bug
Milestone
k6 version
all
OS
all
Docker version and image
No response
Expected Behaviour
With this code:
I expect the
ws.connect()
call to return normally and emit a warning log message, and theResponse
to contain an appropriate error and error code. This is what happens with HTTP requests (which the websocket starts with) whenthrow
isfalse
.Related issue: #2024
Actual Behaviour
An exception will be thrown and
ended with exception, error: websocket: bad handshake
logged.Steps to Reproduce the Problem
Run the code above.
The text was updated successfully, but these errors were encountered: