[Scipy-svn] r5047 - trunk/scipy/lib/lapack/tests

scipy-svn@scip... scipy-svn@scip...
Mon Nov 10 10:46:29 CST 2008


Author: cdavid
Date: 2008-11-10 10:46:24 -0600 (Mon, 10 Nov 2008)
New Revision: 5047

Modified:
   trunk/scipy/lib/lapack/tests/common.py
   trunk/scipy/lib/lapack/tests/test_gesv.py
Log:
Handle missing ssygv in ATLAS clapack.

Modified: trunk/scipy/lib/lapack/tests/common.py
===================================================================
--- trunk/scipy/lib/lapack/tests/common.py	2008-11-10 15:48:31 UTC (rev 5046)
+++ trunk/scipy/lib/lapack/tests/common.py	2008-11-10 16:46:24 UTC (rev 5047)
@@ -42,7 +42,10 @@
 if not CLAPACK_IS_EMPTY:
     FUNCS_CLAPACK = {}
     for f in funcs:
-        FUNCS_CLAPACK[f] = getattr(clapack, f)
+        try:
+            FUNCS_CLAPACK[f] = getattr(clapack, f)
+        except AttributeError:
+            FUNCS_CLAPACK[f] = None
 else:
     FUNCS_CLAPACK = None
 

Modified: trunk/scipy/lib/lapack/tests/test_gesv.py
===================================================================
--- trunk/scipy/lib/lapack/tests/test_gesv.py	2008-11-10 15:48:31 UTC (rev 5046)
+++ trunk/scipy/lib/lapack/tests/test_gesv.py	2008-11-10 16:46:24 UTC (rev 5047)
@@ -60,15 +60,18 @@
     def test_dsygv_3(self):
         self._test_base('dsygv', 'F', 3)
 
-    @dec.skipif(CLAPACK_IS_EMPTY, "Clapack empty, skip flapack test")
+    @dec.skipif(CLAPACK_IS_EMPTY or not FUNCS_CLAPACK["ssygv"], 
+                "Clapack empty, skip flapack test")
     def test_clapack_ssygv_1(self):
         self._test_base('ssygv', 'C', 1)
 
-    @dec.skipif(CLAPACK_IS_EMPTY, "Clapack empty, skip flapack test")
+    @dec.skipif(CLAPACK_IS_EMPTY or not FUNCS_CLAPACK["ssygv"], 
+                "Clapack empty, skip flapack test")
     def test_clapack_ssygv_2(self):
         self._test_base('ssygv', 'C', 2)
 
-    @dec.skipif(CLAPACK_IS_EMPTY, "Clapack empty, skip flapack test")
+    @dec.skipif(CLAPACK_IS_EMPTY or not FUNCS_CLAPACK["ssygv"], 
+                "Clapack empty, skip flapack test")
     def test_clapack_ssygv_3(self):
         self._test_base('ssygv', 'C', 3)
 



More information about the Scipy-svn mailing list