diff options
Diffstat (limited to 'tests/f2s_test.rs')
-rw-r--r-- | tests/f2s_test.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/f2s_test.rs b/tests/f2s_test.rs index 927fa7e..d6249a3 100644 --- a/tests/f2s_test.rs +++ b/tests/f2s_test.rs @@ -75,7 +75,8 @@ fn test_basic() { check!(-0.0); check!(1.0); check!(-1.0); - assert_eq!(pretty(f32::NAN), "NaN"); + assert_eq!(pretty(f32::NAN.copysign(1.0)), "NaN"); + assert_eq!(pretty(f32::NAN.copysign(-1.0)), "NaN"); assert_eq!(pretty(f32::INFINITY), "inf"); assert_eq!(pretty(f32::NEG_INFINITY), "-inf"); } |