1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-01 16:51:13 -05:00
denoland-deno/tests/wpt/runner
Charlie Bellini 8f7787f81b
fix(ext/websocket): don't throw exception when sending to closed socket (#26932)
[The WebSocket specification for the `send`
function](https://developer.mozilla.org/en-US/docs/Web/API/WebSocket/send)
says:

> The browser will throw an exception if you call `send()` when the
connection is in the `CONNECTING` state. If you call `send()` when the
connection is in the `CLOSING` or `CLOSED` states, the browser will
silently discard the data.

and:

> ### Exceptions
> 
> `InvalidStateError`
[`DOMException`](https://developer.mozilla.org/en-US/docs/Web/API/DOMException)
> 
> Thrown if
[`WebSocket.readyState`](https://developer.mozilla.org/en-US/docs/Web/API/WebSocket/readyState)
is `CONNECTING`.

This pull request fixes the current behavior to match the specification.
Also, I believe it fixes #17586.
2024-11-22 00:04:47 +01:00
..
certs chore: move tools/wpt to tests/wpt/runner (#22545) 2024-03-05 00:41:16 +00:00
config.json chore: move tools/wpt to tests/wpt/runner (#22545) 2024-03-05 00:41:16 +00:00
expectation.json fix(ext/websocket): don't throw exception when sending to closed socket (#26932) 2024-11-22 00:04:47 +01:00
runner.ts BREAKING: DENO_FUTURE=1 by default, or welcome to Deno 2.0 (#25213) 2024-08-30 13:58:58 -04:00
testharnessreport.js chore: move tools/wpt to tests/wpt/runner (#22545) 2024-03-05 00:41:16 +00:00
utils.ts chore: show expectation diff for wpt tests (#26014) 2024-10-03 13:01:36 +00:00