summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--numpy/core/tests/test_multiarray.py2
-rw-r--r--numpy/testing/parametric.py10
2 files changed, 6 insertions, 6 deletions
diff --git a/numpy/core/tests/test_multiarray.py b/numpy/core/tests/test_multiarray.py
index 7332e25e3..315f9ac21 100644
--- a/numpy/core/tests/test_multiarray.py
+++ b/numpy/core/tests/test_multiarray.py
@@ -449,7 +449,7 @@ class test_putmask(ParametricTestCase):
assert_array_equal(x,[-1,2,-1])
def testip_byteorder(self):
- return ((self.tst_byteorder,dtype) for dtype in ('>i4','<i4'))
+ return [(self.tst_byteorder,dtype) for dtype in ('>i4','<i4')]
def test_record_array(self):
# Note mixed byteorder.
diff --git a/numpy/testing/parametric.py b/numpy/testing/parametric.py
index 813ee1bc7..43577d7d4 100644
--- a/numpy/testing/parametric.py
+++ b/numpy/testing/parametric.py
@@ -262,11 +262,11 @@ if __name__ == '__main__':
You must return an iterable (list or generator is fine) containing
tuples with the actual method to be called as the first argument,
and the arguments for that call later."""
- return ((self.tstX,i) for i in range(5))
+ return [(self.tstX,i) for i in range(5)]
def testip2(self):
"""Another independent parametric test factory"""
- return ((self.tstY,i) for i in range(5))
+ return [(self.tstY,i) for i in range(5)]
def testip3(self):
"""Test factory combining different subtests.
@@ -281,11 +281,11 @@ if __name__ == '__main__':
A single setUp() call is made for all the tests returned by this
method.
"""
- return ((self.tstXX,i,i+1) for i in range(5))
+ return [(self.tstXX,i,i+1) for i in range(5)]
def testsp2(self):
"""Another shared parametric test factory"""
- return ((self.tstYY,i) for i in range(5))
+ return [(self.tstYY,i) for i in range(5)]
def testsp3(self):
"""Another shared parametric test factory.
@@ -293,7 +293,7 @@ if __name__ == '__main__':
This one simply calls the same test multiple times, without any
arguments. Note that you must still return tuples, even if there
are no arguments."""
- return ((self.tstZZ,) for i in range(10))
+ return [(self.tstZZ,) for i in range(10)]
# This test class runs normally under unittest's default runner