summaryrefslogtreecommitdiff
path: root/cli/tests/unit/net_test.ts
diff options
context:
space:
mode:
Diffstat (limited to 'cli/tests/unit/net_test.ts')
-rw-r--r--cli/tests/unit/net_test.ts15
1 files changed, 15 insertions, 0 deletions
diff --git a/cli/tests/unit/net_test.ts b/cli/tests/unit/net_test.ts
index 4fd253a6c..cda5a536e 100644
--- a/cli/tests/unit/net_test.ts
+++ b/cli/tests/unit/net_test.ts
@@ -255,6 +255,21 @@ unitTest(
);
unitTest(
+ { ignore: Deno.build.os === "windows", perms: { net: true } },
+ async function netUdpBorrowMutError(): Promise<void> {
+ const socket = Deno.listenDatagram({
+ port: 4501,
+ transport: "udp",
+ });
+ // Panic happened on second send: BorrowMutError
+ const a = socket.send(new Uint8Array(), socket.addr);
+ const b = socket.send(new Uint8Array(), socket.addr);
+ await Promise.all([a, b]);
+ socket.close();
+ }
+);
+
+unitTest(
{ ignore: Deno.build.os === "windows", perms: { read: true, write: true } },
async function netUnixPacketSendReceive(): Promise<void> {
const filePath = await Deno.makeTempFile();