1
0
mirror of https://github.com/fafhrd91/actix-net synced 2025-02-07 12:24:24 +01:00

actix-service: Fix clippy warning in benches (#174)

This commit is contained in:
Igor Aleksanov 2020-08-07 11:16:45 +03:00 committed by GitHub
parent 02aaa75591
commit afb0a3c9fc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 4 deletions

View File

@ -293,9 +293,8 @@ where
let start = std::time::Instant::now(); let start = std::time::Instant::now();
// benchmark body // benchmark body
rt.block_on(async move { join_all(srvs.iter_mut().map(|srv| srv.call(()))).await }); rt.block_on(async move { join_all(srvs.iter_mut().map(|srv| srv.call(()))).await });
let elapsed = start.elapsed();
// check that at least first request succeeded // check that at least first request succeeded
elapsed start.elapsed()
}) })
}); });
} }

View File

@ -95,9 +95,8 @@ where
let start = std::time::Instant::now(); let start = std::time::Instant::now();
// benchmark body // benchmark body
rt.block_on(async move { join_all(srvs.iter_mut().map(|srv| srv.call(()))).await }); rt.block_on(async move { join_all(srvs.iter_mut().map(|srv| srv.call(()))).await });
let elapsed = start.elapsed();
// check that at least first request succeeded // check that at least first request succeeded
elapsed start.elapsed()
}) })
}); });
} }