Skip to content

Commit

Permalink
Added test case for issue #15.
Browse files Browse the repository at this point in the history
  • Loading branch information
mamrhein committed Feb 11, 2024
1 parent b4040ab commit 93b788c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/from_float.rs
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,12 @@ mod tests {
check_from_float::<f64>(&test_data);
}

#[test]
fn test_issue_15() {
let test_data = [(1e-22_f64, 0_i128, 0), (-1e-22_f64, 0_i128, 0)];
check_from_float::<f64>(&test_data);
}

#[test]
fn test_fail_overflow_from_f32() {
for f in [
Expand Down

0 comments on commit 93b788c

Please sign in to comment.