[Numpy-svn] r4885 - trunk/numpy/core/tests

numpy-svn at scipy.org numpy-svn at scipy.org
Tue Mar 18 14:02:33 EDT 2008


Author: charris
Date: 2008-03-18 13:02:31 -0500 (Tue, 18 Mar 2008)
New Revision: 4885

Modified:
   trunk/numpy/core/tests/test_umath.py
Log:
Get actual and desired in right order in tests.


Modified: trunk/numpy/core/tests/test_umath.py
===================================================================
--- trunk/numpy/core/tests/test_umath.py	2008-03-18 11:56:24 UTC (rev 4884)
+++ trunk/numpy/core/tests/test_umath.py	2008-03-18 18:02:31 UTC (rev 4885)
@@ -194,8 +194,8 @@
                 x = .5
             fr = f(x)
             fz = f(np.complex(x))
-            assert_almost_equal(fr, fz.real, err_msg='real part %s'%f)
-            assert_almost_equal(0., fz.imag, err_msg='imag part %s'%f)
+            assert_almost_equal(fz.real, fr, err_msg='real part %s'%f)
+            assert_almost_equal(fz.imag, 0., err_msg='imag part %s'%f)
 
     def check_precisions_consistent(self) :
         z = 1 + 1j
@@ -204,7 +204,7 @@
             fcd  = f(np.cdouble(z))
             fcl = f(np.clongdouble(z))
             assert_almost_equal(fcf, fcd, decimal=6, err_msg='fch-fcd %s'%f)
-            assert_almost_equal(fcf, fcl, decimal=6, err_msg='fch-fcl %s'%f)
+            assert_almost_equal(fcl, fcd, decimal=15, err_msg='fch-fcl %s'%f)
 
 
 class TestChoose(NumpyTestCase):




More information about the Numpy-svn mailing list