summaryrefslogtreecommitdiff
path: root/std/http/_io_test.ts
diff options
context:
space:
mode:
authorYusuke Sakurai <kerokerokerop@gmail.com>2020-05-29 21:40:54 +0900
committerGitHub <noreply@github.com>2020-05-29 14:40:54 +0200
commitb97459b5ae3918aae21f0c02342fd7c18189ad3e (patch)
tree137dee6006b3895509741ef1f28933fb8f5be6e2 /std/http/_io_test.ts
parent49c70774012e929b3c77b808edc5a7908bcb6fa2 (diff)
fix: readTrailer didn't evaluate header names by case-insensitive (#4902)
Diffstat (limited to 'std/http/_io_test.ts')
-rw-r--r--std/http/_io_test.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/std/http/_io_test.ts b/std/http/_io_test.ts
index c22ebdf07..3e74e365d 100644
--- a/std/http/_io_test.ts
+++ b/std/http/_io_test.ts
@@ -82,7 +82,7 @@ test("chunkedBodyReader with trailers", async () => {
test("readTrailers", async () => {
const h = new Headers({
- trailer: "deno,node",
+ trailer: "Deno, Node",
});
const trailer = ["deno: land", "node: js", "", ""].join("\r\n");
await readTrailers(h, new BufReader(new Buffer(encode(trailer))));
@@ -112,7 +112,7 @@ test("readTrailer should throw if undeclared headers found in trailer", async ()
});
test("readTrailer should throw if trailer contains prohibited fields", async () => {
- for (const f of ["content-length", "trailer", "transfer-encoding"]) {
+ for (const f of ["Content-Length", "Trailer", "Transfer-Encoding"]) {
const h = new Headers({
trailer: f,
});