mirror of
https://github.com/actix/examples
synced 2025-06-26 17:17:42 +02:00
Minor lints and clippies (#557)
This commit is contained in:
@ -103,7 +103,7 @@ mod tests {
|
||||
.build(manager)
|
||||
.expect("Failed to create pool.");
|
||||
|
||||
let mut app = test::init_service(
|
||||
let app = test::init_service(
|
||||
App::new()
|
||||
.app_data(web::Data::new(pool.clone()))
|
||||
.wrap(middleware::Logger::default())
|
||||
@ -120,7 +120,7 @@ mod tests {
|
||||
})
|
||||
.to_request();
|
||||
|
||||
let resp: models::User = test::call_and_read_body_json(&mut app, req).await;
|
||||
let resp: models::User = test::call_and_read_body_json(&app, req).await;
|
||||
|
||||
assert_eq!(resp.name, "Test user");
|
||||
|
||||
@ -129,7 +129,7 @@ mod tests {
|
||||
.uri(&format!("/user/{}", resp.id))
|
||||
.to_request();
|
||||
|
||||
let resp: models::User = test::call_and_read_body_json(&mut app, req).await;
|
||||
let resp: models::User = test::call_and_read_body_json(&app, req).await;
|
||||
|
||||
assert_eq!(resp.name, "Test user");
|
||||
|
||||
|
Reference in New Issue
Block a user