Skip to content

Commit

Permalink
Fixed tests that are failing in Rust 1.63
Browse files Browse the repository at this point in the history
- Rust version 1.63 changed how they convert float to Durations. Previously they truncated, now they round
  - https://github.com/rust-lang/rust/releases/tag/1.63.0
  - rust-lang/rust#96051
  - 'Rounding is now used when converting a float to a Duration. The converted duration can differ slightly from what it was.'
  • Loading branch information
tkmcmaster committed Sep 7, 2022
1 parent 32171d1 commit a4fec0a
Show file tree
Hide file tree
Showing 9 changed files with 4,670 additions and 4,666 deletions.
4 changes: 4 additions & 0 deletions lib/mod_interval/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -406,6 +406,10 @@ mod tests {
}
}

// https://github.com/rust-lang/rust/releases/tag/1.63.0
// Compatibility Notes
// Rounding is now used when converting a float to a Duration. The converted duration can differ slightly from what it was.
// https://github.com/rust-lang/rust/pull/96051/
#[test]
fn single_segment() {
// start perx, duration, end perx
Expand Down
Loading

0 comments on commit a4fec0a

Please sign in to comment.