[pypy-svn] r52988 - pypy/branch/jit-hotpath/pypy/module/pypyjit/test
arigo at codespeak.net
arigo at codespeak.net
Thu Mar 27 16:37:11 CET 2008
Author: arigo
Date: Thu Mar 27 16:37:11 2008
New Revision: 52988
Modified:
pypy/branch/jit-hotpath/pypy/module/pypyjit/test/test_pypy_c.py
Log:
Fix these tests. They pass :-)
Modified: pypy/branch/jit-hotpath/pypy/module/pypyjit/test/test_pypy_c.py
==============================================================================
--- pypy/branch/jit-hotpath/pypy/module/pypyjit/test/test_pypy_c.py (original)
+++ pypy/branch/jit-hotpath/pypy/module/pypyjit/test/test_pypy_c.py Thu Mar 27 16:37:11 2008
@@ -14,14 +14,16 @@
# some support code...
print >> f, py.code.Source("""
import sys, pypyjit
- pypyjit.enable(main.func_code)
+ pypyjit.enable()
+ pypyjit.setthreshold(3)
def check(args, expected):
- print >> sys.stderr, 'trying:', args
- result = main(*args)
- print >> sys.stderr, 'got:', repr(result)
- assert result == expected
- assert type(result) is type(expected)
+ for i in range(3):
+ print >> sys.stderr, 'trying:', args
+ result = main(*args)
+ print >> sys.stderr, 'got:', repr(result)
+ assert result == expected
+ assert type(result) is type(expected)
""")
for testcase in testcases * 2:
print >> f, "check(%r, %r)" % testcase
More information about the Pypy-commit
mailing list