[pypy-svn] pypy default: Attempt to fix the test on pypy-c-stackless.

arigo commits-noreply at bitbucket.org
Wed Mar 16 14:43:21 CET 2011


Author: Armin Rigo <arigo at tunes.org>
Branch: 
Changeset: r42711:679cf08b7034
Date: 2011-03-16 09:42 -0400
http://bitbucket.org/pypy/pypy/changeset/679cf08b7034/

Log:	Attempt to fix the test on pypy-c-stackless.

diff --git a/pypy/module/_stackless/test/test_composable_coroutine.py b/pypy/module/_stackless/test/test_composable_coroutine.py
--- a/pypy/module/_stackless/test/test_composable_coroutine.py
+++ b/pypy/module/_stackless/test/test_composable_coroutine.py
@@ -11,7 +11,7 @@
         space = gettestobjspace(usemodules=('_stackless',))
         cls.space = space
 
-        cls.w_generator = space.appexec([], """():
+        cls.w_generator_ = space.appexec([], """():
             import _stackless
 
             generators_costate = _stackless.usercostate()
@@ -55,7 +55,7 @@
 
             generator.Yield = Yield
             generator._costate = generators_costate
-            return generator
+            return (generator,)
         """)
 
     def test_simple_costate(self):
@@ -72,7 +72,7 @@
         assert result == [co]
 
     def test_generator(self):
-        generator = self.generator
+        generator, = self.generator_
 
         def squares(n):
             for i in range(n):
@@ -95,7 +95,7 @@
         """
 
         import _stackless
-        generator = self.generator
+        generator, = self.generator_
 
         # you can see how it fails if we don't have two different costates
         # by setting compute_costate to generator._costate instead


More information about the Pypy-commit mailing list