Skip to content

Commit

Permalink
[#124] float64 테스트코드 보충
Browse files Browse the repository at this point in the history
  • Loading branch information
myyrakle committed Jul 15, 2024
1 parent b0b475c commit 5e9d59b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/utils/float.rs
Original file line number Diff line number Diff line change
Expand Up @@ -246,5 +246,9 @@ mod tests {
let f1 = Float64 { value: 2.0 };
let f2 = Float64 { value: 1.0 };
assert_eq!(Ord::cmp(&f1, &f2), std::cmp::Ordering::Greater);

let f1 = Float64 { value: f64::NAN };
let f2 = Float64 { value: f64::NAN };
assert_eq!(Ord::cmp(&f1, &f2), std::cmp::Ordering::Less);
}
}

0 comments on commit 5e9d59b

Please sign in to comment.