Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ignore all errors by default #17

Merged
merged 2 commits into from
Sep 8, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
cargo fmt
  • Loading branch information
programatik29 committed Sep 5, 2021
commit 5bef9693def7465f9aca9877c1147669361c5859
5 changes: 1 addition & 4 deletions src/results.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,7 @@ fn get_percentile(request_times: &Vec<Duration>, pct: f64) -> Duration {
}

let e = format!("failed to calculate P{} avg latency", (1.0 - pct) * 100f64);
let pct = request_times
.chunks(len as usize)
.next()
.expect(&e);
let pct = request_times.chunks(len as usize).next().expect(&e);

let total: f64 = pct.iter().map(|dur| dur.as_secs_f64()).sum();

Expand Down