summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Heller <theller@ctypes.org>2007-11-02 19:11:23 +0000
committerThomas Heller <theller@ctypes.org>2007-11-02 19:11:23 +0000
commit4e7085ece560ebf4daeafff0faed4caf2b4106f2 (patch)
tree3db30750326cb097b54ce25a721752c588b0cb56
parent139c9a56e8360d424c7274dd3d9f80e19a705938 (diff)
downloadcpython-4e7085ece560ebf4daeafff0faed4caf2b4106f2.tar.gz
Enable the full ctypes c_longdouble tests again.
-rw-r--r--Lib/ctypes/test/test_cfuncs.py22
-rw-r--r--Lib/ctypes/test/test_functions.py22
2 files changed, 22 insertions, 22 deletions
diff --git a/Lib/ctypes/test/test_cfuncs.py b/Lib/ctypes/test/test_cfuncs.py
index c5bfa3f889..724100646a 100644
--- a/Lib/ctypes/test/test_cfuncs.py
+++ b/Lib/ctypes/test/test_cfuncs.py
@@ -158,17 +158,17 @@ class CFunctions(unittest.TestCase):
self.failUnlessEqual(self._dll.tf_bd(0, 42.), 14.)
self.failUnlessEqual(self.S(), 42)
-## def test_longdouble(self):
-## self._dll.tf_D.restype = c_longdouble
-## self._dll.tf_D.argtypes = (c_longdouble,)
-## self.failUnlessEqual(self._dll.tf_D(42.), 14.)
-## self.failUnlessEqual(self.S(), 42)
-
-## def test_longdouble_plus(self):
-## self._dll.tf_bD.restype = c_longdouble
-## self._dll.tf_bD.argtypes = (c_byte, c_longdouble)
-## self.failUnlessEqual(self._dll.tf_bD(0, 42.), 14.)
-## self.failUnlessEqual(self.S(), 42)
+ def test_longdouble(self):
+ self._dll.tf_D.restype = c_longdouble
+ self._dll.tf_D.argtypes = (c_longdouble,)
+ self.failUnlessEqual(self._dll.tf_D(42.), 14.)
+ self.failUnlessEqual(self.S(), 42)
+
+ def test_longdouble_plus(self):
+ self._dll.tf_bD.restype = c_longdouble
+ self._dll.tf_bD.argtypes = (c_byte, c_longdouble)
+ self.failUnlessEqual(self._dll.tf_bD(0, 42.), 14.)
+ self.failUnlessEqual(self.S(), 42)
def test_callwithresult(self):
def process_result(result):
diff --git a/Lib/ctypes/test/test_functions.py b/Lib/ctypes/test/test_functions.py
index 2d80c7b0fc..93d895b42c 100644
--- a/Lib/ctypes/test/test_functions.py
+++ b/Lib/ctypes/test/test_functions.py
@@ -143,17 +143,17 @@ class FunctionTestCase(unittest.TestCase):
self.failUnlessEqual(result, -21)
self.failUnlessEqual(type(result), float)
-## def test_longdoubleresult(self):
-## f = dll._testfunc_D_bhilfD
-## f.argtypes = [c_byte, c_short, c_int, c_long, c_float, c_longdouble]
-## f.restype = c_longdouble
-## result = f(1, 2, 3, 4, 5.0, 6.0)
-## self.failUnlessEqual(result, 21)
-## self.failUnlessEqual(type(result), float)
-
-## result = f(-1, -2, -3, -4, -5.0, -6.0)
-## self.failUnlessEqual(result, -21)
-## self.failUnlessEqual(type(result), float)
+ def test_longdoubleresult(self):
+ f = dll._testfunc_D_bhilfD
+ f.argtypes = [c_byte, c_short, c_int, c_long, c_float, c_longdouble]
+ f.restype = c_longdouble
+ result = f(1, 2, 3, 4, 5.0, 6.0)
+ self.failUnlessEqual(result, 21)
+ self.failUnlessEqual(type(result), float)
+
+ result = f(-1, -2, -3, -4, -5.0, -6.0)
+ self.failUnlessEqual(result, -21)
+ self.failUnlessEqual(type(result), float)
def test_longlongresult(self):
try: