summaryrefslogtreecommitdiff
path: root/std/ws
diff options
context:
space:
mode:
authorBartek IwaƄczuk <biwanczuk@gmail.com>2020-02-11 17:24:27 +0100
committerGitHub <noreply@github.com>2020-02-11 17:24:27 +0100
commit61273085e40fb4d992eef4b1b5601e3567c80664 (patch)
tree1ac0f401d4cb897bdb6f88e3a5c47fece2856f89 /std/ws
parente0bcecee6042b219c6626172851af5a25362b948 (diff)
refactor: rewrite tests in std/ to use Deno.test (#3930)
Diffstat (limited to 'std/ws')
-rw-r--r--std/ws/sha1_test.ts2
-rw-r--r--std/ws/test.ts4
2 files changed, 2 insertions, 4 deletions
diff --git a/std/ws/sha1_test.ts b/std/ws/sha1_test.ts
index 43b4bc3c1..9d0d90ea4 100644
--- a/std/ws/sha1_test.ts
+++ b/std/ws/sha1_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { test } from "../testing/mod.ts";
+const { test } = Deno;
import { assertEquals } from "../testing/asserts.ts";
import { Sha1 } from "./sha1.ts";
diff --git a/std/ws/test.ts b/std/ws/test.ts
index d3148f7ad..a8dbc903c 100644
--- a/std/ws/test.ts
+++ b/std/ws/test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { BufReader, BufWriter } from "../io/bufio.ts";
import { assert, assertEquals, assertThrowsAsync } from "../testing/asserts.ts";
-import { runIfMain, test } from "../testing/mod.ts";
+const { test } = Deno;
import { TextProtoReader } from "../textproto/mod.ts";
import * as bytes from "../bytes/mod.ts";
import {
@@ -326,5 +326,3 @@ test("WebSocket.send(), WebSocket.ping() should be exclusive", async (): Promise
assertEquals(third.opcode, OpCode.BinaryFrame);
assertEquals(bytes.equal(third.payload, new Uint8Array([3])), true);
});
-
-runIfMain(import.meta);