summaryrefslogtreecommitdiff
path: root/numpy/testing/parametric.py
diff options
context:
space:
mode:
authorStefan van der Walt <stefan@sun.ac.za>2007-08-20 16:42:16 +0000
committerStefan van der Walt <stefan@sun.ac.za>2007-08-20 16:42:16 +0000
commit47221fe49a26140a57c6af6569afbaf055db15c8 (patch)
treee023abc1d38565ea460f0c0211b324cb4f7234a5 /numpy/testing/parametric.py
parentba77c98e0cb21515c0117669e5c0ea13a035dc0c (diff)
downloadnumpy-47221fe49a26140a57c6af6569afbaf055db15c8.tar.gz
Fix parametric testing for Python 2.4.
Diffstat (limited to 'numpy/testing/parametric.py')
-rw-r--r--numpy/testing/parametric.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/numpy/testing/parametric.py b/numpy/testing/parametric.py
index 8ed3ea4b5..94f7accf8 100644
--- a/numpy/testing/parametric.py
+++ b/numpy/testing/parametric.py
@@ -161,8 +161,12 @@ class ParametricTestCase(unittest.TestCase):
if result is None: result = self.defaultTestResult()
+ try:
+ _testMethodName = getattr(self,"_testMethodName")
+ except:
+ _testMethodName = getattr(self,"_TestCase__testMethodName")
+
# Independent tests: each gets its own setup/teardown
- _testMethodName = getattr(self,"_testMethodName", "runTest")
if _testMethodName.startswith(self._indepParTestPrefix):
for t in getattr(self,_testMethodName)():
self.run_test(t,result)