pub fn progress_reading(
done: u64,
total: u64,
elapsed: Option<Duration>,
) -> StringExpand description
The words beside a determinate bar: what is done over what there is, then the whole seconds the wait has taken when that is known.
Never a remaining time, an arrival time or a rate, for Awaiting’s
reason. The numbers are raw, in the description’s unit. Padding between the
bar and the reading is the host’s.
assert_eq!(progress_reading(17, 40, None), "17/40");
assert_eq!(progress_reading(17, 40, Some(Duration::from_millis(4900))), "17/40 4s");