1
0
mirror of https://github.com/actix/examples synced 2024-11-27 16:02:57 +01:00

fix test for forms/form (#610)

This commit is contained in:
Taisei Mima 2023-03-09 10:16:35 +09:00 committed by GitHub
parent 080db60175
commit 6571dfef82
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -119,7 +119,7 @@ mod tests {
name: "John".to_string(), name: "John".to_string(),
}) })
.to_request(); .to_request();
let resp: ServiceResponse = app.call(req).await.unwrap(); let resp: ServiceResponse = test::call_service(&app, req).await;
assert_eq!(resp.status(), StatusCode::OK); assert_eq!(resp.status(), StatusCode::OK);
assert_eq!( assert_eq!(
@ -164,7 +164,7 @@ mod tests {
name: "John".to_string(), name: "John".to_string(),
}) })
.to_request(); .to_request();
let resp: ServiceResponse = app.call(req).await.unwrap(); let resp: ServiceResponse = test::call_service(&app, req).await;
assert_eq!(resp.status(), StatusCode::OK); assert_eq!(resp.status(), StatusCode::OK);
assert_eq!( assert_eq!(
@ -208,7 +208,7 @@ mod tests {
name: "John".to_string(), name: "John".to_string(),
}) })
.to_request(); .to_request();
let resp: ServiceResponse = app.call(req).await.unwrap(); let resp: ServiceResponse = test::call_service(&app, req).await;
assert_eq!(resp.status(), StatusCode::OK); assert_eq!(resp.status(), StatusCode::OK);
assert_eq!( assert_eq!(