diff options
| author | Ryan Dahl <ry@tinyclouds.org> | 2019-03-06 19:42:24 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-03-06 19:42:24 -0500 |
| commit | caa383a5835c167bf6657120ad3c1c5009670785 (patch) | |
| tree | 2f350928e23e472278b9c3ebd798f13169b6d581 /textproto | |
| parent | e36edfdb3fd4709358a5f499f13cfe3d53c2b4f7 (diff) | |
Rename assertEq to assertEquals (denoland/deno_std#242)
After some discussion it was found that assertEquals is more common
in JS (vs assertEqual, assertEq) and sounds better in the negated form:
assertNotEquals vs assertNE.
Original: https://github.com/denoland/deno_std/commit/4cf39d4a1420b8153cd78d03d03ef843607ae506
Diffstat (limited to 'textproto')
| -rw-r--r-- | textproto/test.ts | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/textproto/test.ts b/textproto/test.ts index e74c360e1..5d1b64b11 100644 --- a/textproto/test.ts +++ b/textproto/test.ts @@ -6,7 +6,7 @@ import { BufReader } from "../io/bufio.ts"; import { TextProtoReader, append } from "./mod.ts"; import { stringsReader } from "../io/util.ts"; -import { assert, assertEq } from "../testing/asserts.ts"; +import { assert, assertEquals } from "../testing/asserts.ts"; import { test } from "../testing/mod.ts"; function reader(s: string): TextProtoReader { @@ -16,15 +16,15 @@ function reader(s: string): TextProtoReader { test(async function textprotoReader() { let r = reader("line1\nline2\n"); let [s, err] = await r.readLine(); - assertEq(s, "line1"); + assertEquals(s, "line1"); assert(err == null); [s, err] = await r.readLine(); - assertEq(s, "line2"); + assertEquals(s, "line2"); assert(err == null); [s, err] = await r.readLine(); - assertEq(s, ""); + assertEquals(s, ""); assert(err == "EOF"); }); @@ -47,7 +47,7 @@ test(async function textprotoReadMIMEHeader() { test(async function textprotoReadMIMEHeaderSingle() { let r = reader("Foo: bar\n\n"); let [m, err] = await r.readMIMEHeader(); - assertEq(m.get("Foo"), "bar"); + assertEquals(m.get("Foo"), "bar"); assert(!err); }); @@ -88,12 +88,12 @@ test(async function textprotoAppend() { const u1 = enc.encode("Hello "); const u2 = enc.encode("World"); const joined = append(u1, u2); - assertEq(dec.decode(joined), "Hello World"); + assertEquals(dec.decode(joined), "Hello World"); }); test(async function textprotoReadEmpty() { let r = reader(""); let [, err] = await r.readMIMEHeader(); // Should not crash! - assertEq(err, "EOF"); + assertEquals(err, "EOF"); }); |
