提交 03121837 authored 作者: Olivier Delalleau's avatar Olivier Delalleau

Added back a test with pickle protocol 0 since it is still better if it works

上级 000e61d3
......@@ -429,6 +429,9 @@ class T_picklefunction(unittest.TestCase):
f = function([x, In(a, value=1.0,name='a'), In(s, value=0.0, update=s+a*x, mutable=True)], s+a*x)
try:
# Note that here we also test protocol 0 on purpose, since it
# should work (even though one should not use it).
g = cPickle.loads(cPickle.dumps(f, protocol=0))
g = cPickle.loads(cPickle.dumps(f, protocol=-1))
except NotImplementedError, e:
if e[0].startswith('DebugMode is not picklable'):
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论