aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Lib/test/test_math.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_math.py')
-rw-r--r--Lib/test/test_math.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/Lib/test/test_math.py b/Lib/test/test_math.py
index 913a60bf9e0..d14336f8bac 100644
--- a/Lib/test/test_math.py
+++ b/Lib/test/test_math.py
@@ -1214,6 +1214,12 @@ class MathTests(unittest.TestCase):
self.assertEqual(math.ldexp(NINF, n), NINF)
self.assertTrue(math.isnan(math.ldexp(NAN, n)))
+ @requires_IEEE_754
+ def testLdexp_denormal(self):
+ # Denormal output incorrectly rounded (truncated)
+ # on some Windows.
+ self.assertEqual(math.ldexp(6993274598585239, -1126), 1e-323)
+
def testLog(self):
self.assertRaises(TypeError, math.log)
self.assertRaises(TypeError, math.log, 1, 2, 3)