summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_math.py
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@haypocalc.com>2011-06-01 11:19:07 (GMT)
committerVictor Stinner <victor.stinner@haypocalc.com>2011-06-01 11:19:07 (GMT)
commitebbbdafd8782b02eaf05f5c99ed000dbd6ad0ae1 (patch)
tree1410655038edec7924f0b23bcd9fdc15aed0c01f /Lib/test/test_math.py
parentfce9233e93cb217a31d8c5b1776b4ec226595dc1 (diff)
parent88701e27e90c0b70e2b22b06ad8bbfa231cf99dc (diff)
downloadcpython-ebbbdafd8782b02eaf05f5c99ed000dbd6ad0ae1.zip
cpython-ebbbdafd8782b02eaf05f5c99ed000dbd6ad0ae1.tar.gz
cpython-ebbbdafd8782b02eaf05f5c99ed000dbd6ad0ae1.tar.bz2
(Merge 3.2) Close #12230: Mac OS X Tiger (10.4) has a kernel bug: sometimes,
the file descriptor of a pipe closed in the parent process is valid in the child process according to fstat(), but the mode of the file descriptor is invalid, and read or write raise an error. test.support.requires_mac_ver() is now a decorator, as suggested by Ezio Melotti, and its docstring is fixed (linux_version => mac_ver).
Diffstat (limited to 'Lib/test/test_math.py')
-rw-r--r--Lib/test/test_math.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/Lib/test/test_math.py b/Lib/test/test_math.py
index 636ff2c..715003a 100644
--- a/Lib/test/test_math.py
+++ b/Lib/test/test_math.py
@@ -670,10 +670,9 @@ class MathTests(unittest.TestCase):
self.assertTrue(math.isnan(math.log2(NAN)))
@requires_IEEE_754
+ # log2() is not accurate enough on Mac OS X Tiger (10.4)
+ @support.requires_mac_ver(10, 5)
def testLog2Exact(self):
- # log2() is not accurate enough on Mac OS X Tiger (10.4)
- support.requires_mac_ver(10, 5)
-
# Check that we get exact equality for log2 of powers of 2.
actual = [math.log2(math.ldexp(1.0, n)) for n in range(-1074, 1024)]
expected = [float(n) for n in range(-1074, 1024)]