1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-08-19 20:35:36 +02:00

Rename test::call_success to test::call_service

This commit is contained in:
Nikolay Kim
2019-04-15 07:44:07 -07:00
parent 09cdf1e302
commit 7a28b32f6d
11 changed files with 74 additions and 50 deletions

View File

@@ -500,15 +500,15 @@ mod tests {
})),
);
let resp =
test::call_success(&mut srv, TestRequest::with_uri("/index").to_request());
test::call_service(&mut srv, TestRequest::with_uri("/index").to_request());
assert_eq!(resp.status(), StatusCode::OK);
let resp =
test::call_success(&mut srv, TestRequest::with_uri("/login").to_request());
test::call_service(&mut srv, TestRequest::with_uri("/login").to_request());
assert_eq!(resp.status(), StatusCode::OK);
let c = resp.response().cookies().next().unwrap().to_owned();
let resp = test::call_success(
let resp = test::call_service(
&mut srv,
TestRequest::with_uri("/index")
.cookie(c.clone())
@@ -516,7 +516,7 @@ mod tests {
);
assert_eq!(resp.status(), StatusCode::CREATED);
let resp = test::call_success(
let resp = test::call_service(
&mut srv,
TestRequest::with_uri("/logout")
.cookie(c.clone())