提交 cb831893 authored 作者: Pascal Lamblin's avatar Pascal Lamblin

Fix test that was not testing what it should

I corrected what I thought was a typo in a previous pep8 commit, but this change was also needed for the test to make sense.
上级 6abfed52
......@@ -250,7 +250,7 @@ class Test_SharedVariable(unittest.TestCase):
f(b, 8)
assert b.get_value() == 8
b = shared(numpy.zeros((5, 5), dtype='float32'), allow_downcast=True)
b = shared(numpy.zeros((5, 5), dtype='float32'))
self.assertRaises(TypeError, f, b, numpy.random.rand(5, 5))
def test_tensor_floatX(self):
......@@ -303,6 +303,5 @@ class Test_SharedVariable(unittest.TestCase):
f(b, [8])
assert b.get_value() == 8
b = shared(numpy.zeros((5, 5), dtype='float32'),
allow_downcast=True)
b = shared(numpy.zeros((5, 5), dtype='float32'))
self.assertRaises(TypeError, f, b, numpy.random.rand(5, 5))
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论