mirror of
https://github.com/denoland/deno.git
synced 2024-12-01 16:51:13 -05:00
enable websocket tests
This commit is contained in:
parent
0488c79bba
commit
f32d070c12
2 changed files with 4 additions and 6 deletions
|
@ -114,7 +114,7 @@ where
|
||||||
let (sender, conn) = hyper::client::conn::http1::handshake(io).await?;
|
let (sender, conn) = hyper::client::conn::http1::handshake(io).await?;
|
||||||
(
|
(
|
||||||
tokio::task::spawn(async move {
|
tokio::task::spawn(async move {
|
||||||
conn.await?;
|
conn.with_upgrades().await?;
|
||||||
Ok::<_, AnyError>(())
|
Ok::<_, AnyError>(())
|
||||||
}),
|
}),
|
||||||
sender,
|
sender,
|
||||||
|
@ -135,7 +135,7 @@ where
|
||||||
// Spawn a task to poll the connection, driving the HTTP state
|
// Spawn a task to poll the connection, driving the HTTP state
|
||||||
(
|
(
|
||||||
tokio::task::spawn(async move {
|
tokio::task::spawn(async move {
|
||||||
conn.await?;
|
conn.with_upgrades().await?;
|
||||||
Ok::<_, AnyError>(())
|
Ok::<_, AnyError>(())
|
||||||
}),
|
}),
|
||||||
sender,
|
sender,
|
||||||
|
|
|
@ -852,7 +852,7 @@ Deno.test("[node/http] HTTPS server", async () => {
|
||||||
|
|
||||||
Deno.test(
|
Deno.test(
|
||||||
"[node/http] client upgrade",
|
"[node/http] client upgrade",
|
||||||
{ permissions: { net: true }, ignore: true },
|
{ permissions: { net: true } },
|
||||||
async () => {
|
async () => {
|
||||||
const { promise: serverClosed, resolve: resolveServer } = Promise
|
const { promise: serverClosed, resolve: resolveServer } = Promise
|
||||||
.withResolvers<void>();
|
.withResolvers<void>();
|
||||||
|
@ -1648,9 +1648,7 @@ Deno.test("[node/http] In ClientRequest, option.hostname has precedence over opt
|
||||||
await responseReceived.promise;
|
await responseReceived.promise;
|
||||||
});
|
});
|
||||||
|
|
||||||
const IGNORED_Y =
|
Deno.test("[node/http] upgraded socket closes when the server closed without closing handshake", async () => {
|
||||||
"[node/http] upgraded socket closes when the server closed without closing handshake";
|
|
||||||
Deno.test(IGNORED_Y, { ignore: true }, async () => {
|
|
||||||
const clientSocketClosed = Promise.withResolvers<void>();
|
const clientSocketClosed = Promise.withResolvers<void>();
|
||||||
const serverProcessClosed = Promise.withResolvers<void>();
|
const serverProcessClosed = Promise.withResolvers<void>();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue