[pypy-commit] pypy py3k: 2to3

pjenvey noreply at buildbot.pypy.org
Fri May 10 22:53:06 CEST 2013


Author: Philip Jenvey <pjenvey at underboss.org>
Branch: py3k
Changeset: r63971:48383cc7b1b0
Date: 2013-05-10 13:52 -0700
http://bitbucket.org/pypy/pypy/changeset/48383cc7b1b0/

Log:	2to3

diff --git a/pypy/interpreter/test/test_zzpickle_and_slow.py b/pypy/interpreter/test/test_zzpickle_and_slow.py
--- a/pypy/interpreter/test/test_zzpickle_and_slow.py
+++ b/pypy/interpreter/test/test_zzpickle_and_slow.py
@@ -508,16 +508,16 @@
                 yield 42 + i
         g = f(4)
         g2 = copy.deepcopy(g)
-        res = g.next()
+        res = next(g)
         assert res == 42
-        res = g2.next()
+        res = next(g2)
         assert res == 42
         g3 = copy.deepcopy(g)
-        res = g.next()
+        res = next(g)
         assert res == 43
-        res = g2.next()
+        res = next(g2)
         assert res == 43
-        res = g3.next()
+        res = next(g3)
         assert res == 43
 
     def test_shallowcopy_generator(self):
@@ -533,20 +533,20 @@
                 n -= 1
         g = f(2)
         g2 = copy.copy(g)
-        res = g.next()
+        res = next(g)
         assert res == 44
-        res = g2.next()
+        res = next(g2)
         assert res == 44
         g3 = copy.copy(g)
-        res = g.next()
+        res = next(g)
         assert res == 43
-        res = g2.next()
+        res = next(g2)
         assert res == 43
-        res = g3.next()
+        res = next(g3)
         assert res == 43
         g4 = copy.copy(g2)
         for i in range(2):
-            raises(StopIteration, g.next)
-            raises(StopIteration, g2.next)
-            raises(StopIteration, g3.next)
-            raises(StopIteration, g4.next)
+            raises(StopIteration, next, g)
+            raises(StopIteration, next, g2)
+            raises(StopIteration, next, g3)
+            raises(StopIteration, next, g4)


More information about the pypy-commit mailing list