From 903444015cc1978a6c940b922e41b0ba6d0172ed Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Mon, 30 Nov 2015 10:53:20 -0800 Subject: std: Bump time margin in std::time tests I believe that because Windows' unit of resolution is 100ns that this unit of time will ensure that the assertions will hold true as it's representable in the native format. cc #29970 --- src/libstd/time/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/libstd') diff --git a/src/libstd/time/mod.rs b/src/libstd/time/mod.rs index 261f3e266d7..d400d12e23f 100644 --- a/src/libstd/time/mod.rs +++ b/src/libstd/time/mod.rs @@ -235,7 +235,7 @@ mod tests { let (a, b) = ($a, $b); if a != b { let (a, b) = if a > b {(a, b)} else {(b, a)}; - assert!(a - Duration::new(0, 1) <= b); + assert!(a - Duration::new(0, 100) <= b); } }) } -- cgit 1.4.1-3-g733a5