summaryrefslogtreecommitdiff
path: root/test_util/src
diff options
context:
space:
mode:
authorLeo Kettmeir <crowlkats@toaxl.com>2023-07-28 09:01:06 +0200
committerGitHub <noreply@github.com>2023-07-28 09:01:06 +0200
commit5cb1d18439f562c8004a941b0f56ed034a44b052 (patch)
treee0b3ae76685760a50c1089c8885b6f6369d49282 /test_util/src
parentcbfa98ea0bf4ee994bf564671ece514eb4efae1f (diff)
feat: Deno.createHttpClient allowHost (#19689)
This adds an option to allow using the host header in a fetch call. Closes https://github.com/denoland/deno/issues/16840 Ref https://github.com/denoland/deno/issues/11017
Diffstat (limited to 'test_util/src')
-rw-r--r--test_util/src/lib.rs5
1 files changed, 1 insertions, 4 deletions
diff --git a/test_util/src/lib.rs b/test_util/src/lib.rs
index 12d5675d2..dcf12d860 100644
--- a/test_util/src/lib.rs
+++ b/test_util/src/lib.rs
@@ -728,10 +728,7 @@ async fn main_server(
req: Request<Body>,
) -> Result<Response<Body>, hyper::http::Error> {
return match (req.method(), req.uri().path()) {
- (
- &hyper::Method::POST | &hyper::Method::PATCH | &hyper::Method::PUT,
- "/echo_server",
- ) => {
+ (_, "/echo_server") => {
let (parts, body) = req.into_parts();
let mut response = Response::new(body);