[pypy-commit] pypy py3k: save the source of applevel direct tests in a temporary file: this way, we get nicer tracebacks
antocuni
noreply at buildbot.pypy.org
Thu Feb 9 16:12:08 CET 2012
Author: Antonio Cuni <anto.cuni at gmail.com>
Branch: py3k
Changeset: r52297:5c66b92f0617
Date: 2012-02-09 15:35 +0100
http://bitbucket.org/pypy/pypy/changeset/5c66b92f0617/
Log: save the source of applevel direct tests in a temporary file: this
way, we get nicer tracebacks
diff --git a/pypy/conftest.py b/pypy/conftest.py
--- a/pypy/conftest.py
+++ b/pypy/conftest.py
@@ -213,8 +213,10 @@
raise AssertionError("DID NOT RAISE")
"""
source = py.code.Source(target)[1:].deindent()
+ pyfile = udir.join('src.py')
+ pyfile.write(helpers + str(source))
res, stdout, stderr = runsubprocess.run_subprocess(
- python, ["-c", helpers + str(source)])
+ python, [str(pyfile)])
print source
print >> sys.stdout, stdout
print >> sys.stderr, stderr
More information about the pypy-commit
mailing list