We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b752788 commit d0a4d79Copy full SHA for d0a4d79
library/std/tests/thread.rs
@@ -24,11 +24,6 @@ fn sleep_until() {
24
let deadline = now + period;
25
thread::sleep_until(deadline);
26
27
- let margin = Duration::from_micros(100);
28
let elapsed = now.elapsed();
29
- assert!(
30
- (period..period + margin).contains(&elapsed),
31
- "elapsed: {} microseconds, expected 100_000 to 100_100",
32
- elapsed.as_micros()
33
- );
+ assert!(elapsed >= period);
34
}
0 commit comments