Commit b7a2405
committed
Resolve duration_suboptimal_units pedantic clippy lint
warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
--> tests/repo/progress.rs:14:36
|
14 | tick: Instant::now() + Duration::from_millis(2000),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
= note: `-W clippy::duration-suboptimal-units` implied by `-W clippy::pedantic`
= help: to override `-W clippy::pedantic` add `#[allow(clippy::duration_suboptimal_units)]`
help: try using from_secs
|
14 - tick: Instant::now() + Duration::from_millis(2000),
14 + tick: Instant::now() + Duration::from_secs(2),
|1 parent 2efa9ff commit b7a2405
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
| 14 | + | |
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| |||
0 commit comments