提交 6e356400 authored 作者: Frederic Bastien's avatar Frederic Bastien

Fix error message expected as it changed in numpy 1.6

上级 5a3ad36e
......@@ -283,7 +283,10 @@ class TestComputeTestValue(unittest.TestCase):
n_steps=k)
assert False
except ValueError, e:
assert e.message.startswith("shape mismatch")
# The first message is for numpy before 1.6
# The second is a new message in numpy 1.6
assert (e.message.startswith("shape mismatch") or
e.message.startswith("operands could not be broadcast together with shapes"))
finally:
theano.config.compute_test_value = orig_compute_test_value
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论