[pypy-svn] r54912 - pypy/branch/win32port/pypy/rlib/test

afa at codespeak.net afa at codespeak.net
Mon May 19 00:03:42 CEST 2008


Author: afa
Date: Mon May 19 00:03:40 2008
New Revision: 54912

Modified:
   pypy/branch/win32port/pypy/rlib/test/test_rmmap.py
   pypy/branch/win32port/pypy/rlib/test/test_rpoll.py
Log:
update tests to use the simpler compile() function.
Thanks Maciej.


Modified: pypy/branch/win32port/pypy/rlib/test/test_rmmap.py
==============================================================================
--- pypy/branch/win32port/pypy/rlib/test/test_rmmap.py	(original)
+++ pypy/branch/win32port/pypy/rlib/test/test_rmmap.py	Mon May 19 00:03:40 2008
@@ -373,7 +373,7 @@
         f.close()
 
     def test_translated(self):
-        from pypy.translator.interactive import Translation
+        from pypy.translator.c.test.test_genc import compile
 
         def func(no):
             m = mmap.mmap(no, 1)
@@ -381,6 +381,4 @@
             m.close()
             return r
 
-        t = Translation(func)
-        fc = t.compile_c([int])
-
+        compile(func, [int])

Modified: pypy/branch/win32port/pypy/rlib/test/test_rpoll.py
==============================================================================
--- pypy/branch/win32port/pypy/rlib/test/test_rpoll.py	(original)
+++ pypy/branch/win32port/pypy/rlib/test/test_rpoll.py	Mon May 19 00:03:40 2008
@@ -49,10 +49,9 @@
     serv.close()
 
 def test_translate():
-    from pypy.translator.interactive import Translation
+    from pypy.translator.c.test.test_genc import compile
 
     def func():
         poll({})
 
-    t = Translation(func)
-    fc = t.compile_c([])
+    compile(func, [])



More information about the Pypy-commit mailing list