diff options
| author | bors <bors@rust-lang.org> | 2018-11-18 17:27:45 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2018-11-18 17:27:45 +0000 |
| commit | 13c9439925797cd7a65c917d047c07a500d9bfe6 (patch) | |
| tree | cc22dabe5f2a808fbf04264cfb96de7b2a33bee0 /src/libstd | |
| parent | d1c2cbf90a12bce0d4214ae27feda4f7d73c0510 (diff) | |
| parent | 7a99b6db15fb657128a7cccd1f22faae287f0776 (diff) | |
| download | rust-13c9439925797cd7a65c917d047c07a500d9bfe6.tar.gz rust-13c9439925797cd7a65c917d047c07a500d9bfe6.zip | |
Auto merge of #56017 - alexcrichton:debug-test, r=alexcrichton
std: Add debugging for a failing test on appveyor I'm not sure why this is failing, so let's hopefully get some more information to help investigation!
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/time.rs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/libstd/time.rs b/src/libstd/time.rs index 90ab3491599..d124cf53dda 100644 --- a/src/libstd/time.rs +++ b/src/libstd/time.rs @@ -481,7 +481,8 @@ 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, 100) <= b); + assert!(a - Duration::new(0, 100) <= b, + "{:?} is not almost equal to {:?}", a, b); } }) } @@ -503,7 +504,10 @@ mod tests { fn instant_math() { let a = Instant::now(); let b = Instant::now(); + println!("a: {:?}", a); + println!("b: {:?}", b); let dur = b.duration_since(a); + println!("dur: {:?}", dur); assert_almost_eq!(b - dur, a); assert_almost_eq!(a + dur, b); |
