aboutsummaryrefslogtreecommitdiff
path: root/test/gentests.py
diff options
context:
space:
mode:
authorPhilipp Hagemeister <phihag@phihag.de>2012-11-29 16:35:57 +0100
committerPhilipp Hagemeister <phihag@phihag.de>2012-11-29 16:35:57 +0100
commit8af4ed7b4fb20190ec72e9ab6347e99deabe9bce (patch)
tree818e8e21bcacd473b06ef94e5f105115422e9d55 /test/gentests.py
parent743b28ce1155df348bbb828fcb316d57c8704328 (diff)
Fix 2.6 nosetests
Diffstat (limited to 'test/gentests.py')
-rwxr-xr-xtest/gentests.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/gentests.py b/test/gentests.py
index da4e3c2f6..6f82ae8fa 100755
--- a/test/gentests.py
+++ b/test/gentests.py
@@ -52,13 +52,14 @@ try:
except AttributeError: # Python 2.6
def _skip_unless(cond, reason='No reason given'):
def resfunc(f):
- def wfunc(*args, **kwargs):
+ # Start the function name with test to appease nosetests-2.6
+ def test_wfunc(*args, **kwargs):
if cond:
return f(*args, **kwargs)
else:
print('Skipped test')
return
- return wfunc
+ return test_wfunc
return resfunc
_skip = lambda *args, **kwargs: _skip_unless(False, *args, **kwargs)