From c66f7b6d8d1d7481eee91d9ff898fd4eaddfdeea Mon Sep 17 00:00:00 2001 From: Matt Mastracci Date: Fri, 26 Jan 2024 10:33:55 -0500 Subject: fix(ext/http): smarter handling of Accept-Encoding (#22130) --- cli/tests/unit/serve_test.ts | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'cli') diff --git a/cli/tests/unit/serve_test.ts b/cli/tests/unit/serve_test.ts index 9d06860e0..09bd86015 100644 --- a/cli/tests/unit/serve_test.ts +++ b/cli/tests/unit/serve_test.ts @@ -2649,6 +2649,13 @@ const compressionTestCases = [ out: { "Content-Type": "text/plain", "Cache-Control": "no-transform" }, expect: null, }, + { + name: "BadHeader", + length: 1024, + in: { "Accept-Encoding": "\x81" }, + out: { "Content-Type": "text/plain", "Cache-Control": "no-transform" }, + expect: null, + }, ]; for (const testCase of compressionTestCases) { -- cgit v1.2.3