[pypy-svn] r28312 - pypy/dist/pypy/interpreter/test
pedronis at codespeak.net
pedronis at codespeak.net
Mon Jun 5 12:01:57 CEST 2006
Author: pedronis
Date: Mon Jun 5 12:01:56 2006
New Revision: 28312
Modified:
pypy/dist/pypy/interpreter/test/test_pickle.py
Log:
now test pickle traceback fails with a recursion problem
Modified: pypy/dist/pypy/interpreter/test/test_pickle.py
==============================================================================
--- pypy/dist/pypy/interpreter/test/test_pickle.py (original)
+++ pypy/dist/pypy/interpreter/test/test_pickle.py Mon Jun 5 12:01:56 2006
@@ -1,4 +1,5 @@
def _attach_helpers(space):
+ from pypy.interpreter import pytraceback
def hide_top_frame(space, w_frame):
w_last = None
while w_frame.f_back:
@@ -132,7 +133,7 @@
assert type(f1) is type(f2)
assert dir(f1) == dir(f2)
assert f1.__doc__ == f2.__doc__
- assert f2.f_back is None # mecause we pruned it
+ assert f2.f_back is None # because we pruned it
assert f1.f_builtins is f2.f_builtins
assert f1.f_code == f2.f_code
assert f1.f_exc_traceback is f2.f_exc_traceback
@@ -144,7 +145,7 @@
assert f1.f_trace is f2.f_trace
def test_pickle_traceback(self):
- skip("in-progress")
+ skip("in-progress: recursion problem")
def f():
try:
raise Exception()
@@ -154,6 +155,7 @@
return tb
import pickle
tb = f()
+ saved = hide_top_frame(tb.tb_frame)
pckl = pickle.dumps(tb)
result = pickle.loads(pckl)
@@ -189,6 +191,8 @@
assert f1.f_restricted is f2.f_restricted
assert f1.f_trace is f2.f_trace
+ restore_top_frame(tb.tb_frame, saved)
+
def test_pickle_module(self):
import pickle
mod = pickle
More information about the Pypy-commit
mailing list