[pypy-svn] r46336 - pypy/branch/merging/rpython/module/test
arigo at codespeak.net
arigo at codespeak.net
Wed Sep 5 13:18:43 CEST 2007
Author: arigo
Date: Wed Sep 5 13:18:42 2007
New Revision: 46336
Modified:
pypy/branch/merging/rpython/module/test/test_ll_os.py
pypy/branch/merging/rpython/module/test/test_posix.py
Log:
Repeat r45631: move the test so that it is llinterpreted.
Modified: pypy/branch/merging/rpython/module/test/test_ll_os.py
==============================================================================
--- pypy/branch/merging/rpython/module/test/test_ll_os.py (original)
+++ pypy/branch/merging/rpython/module/test/test_ll_os.py Wed Sep 5 13:18:42 2007
@@ -48,18 +48,6 @@
assert file(filename).read().strip() == '2'
os.unlink(filename)
-def test_os_wstar():
- from pypy.rpython.module.ll_os import RegisterOs
- for name in RegisterOs.w_star:
- if not hasattr(os, name):
- continue
- def fun(s):
- return getattr(os, name)(s)
-
- fn = compile(fun, [int])
- for value in [0, 1, 127, 128, 255]:
- assert fn(value) == fun(value)
-
class ExpectTestOs:
def setup_class(cls):
if not hasattr(os, 'ttyname'):
Modified: pypy/branch/merging/rpython/module/test/test_posix.py
==============================================================================
--- pypy/branch/merging/rpython/module/test/test_posix.py (original)
+++ pypy/branch/merging/rpython/module/test/test_posix.py Wed Sep 5 13:18:42 2007
@@ -118,6 +118,18 @@
return os.getuid()
assert self.interpret(f, []) == f()
+ def test_os_wstar(self):
+ from pypy.rpython.module.ll_os import RegisterOs
+ for name in RegisterOs.w_star:
+ if not hasattr(os, name):
+ continue
+ def fun(s):
+ return getattr(os, name)(s)
+
+ for value in [0, 1, 127, 128, 255]:
+ res = self.interpret(fun, [value])
+ assert res == fun(value)
+
class TestLLtype(BaseTestPosix, LLRtypeMixin):
if False and hasattr(os, 'uname'):
def test_os_uname(self):
More information about the Pypy-commit
mailing list