Use IntoFuture for test RequestBuilder (#2470)

This commit is contained in:
David Pedersen
2023-12-30 18:23:53 +01:00
committed by GitHub
parent 3b43b257e7
commit 7ea7e9f618
32 changed files with 289 additions and 351 deletions
+3 -3
View File
@@ -221,7 +221,7 @@ mod tests {
};
let client = TestClient::new(app);
let res = client.post("/").body(input.encode_to_vec()).send().await;
let res = client.post("/").body(input.encode_to_vec()).await;
let body = res.text().await;
@@ -249,7 +249,7 @@ mod tests {
};
let client = TestClient::new(app);
let res = client.post("/").body(input.encode_to_vec()).send().await;
let res = client.post("/").body(input.encode_to_vec()).await;
assert_eq!(res.status(), StatusCode::UNPROCESSABLE_ENTITY);
}
@@ -284,7 +284,7 @@ mod tests {
};
let client = TestClient::new(app);
let res = client.post("/").body(input.encode_to_vec()).send().await;
let res = client.post("/").body(input.encode_to_vec()).await;
assert_eq!(
res.headers()["content-type"],