mirror of
https://github.com/tinygrad/tinygrad.git
synced 2026-04-29 03:00:14 -04:00
fix typing for test_ops (#6520)
mostly passed TYPED=1 python3 -m pytest -n=auto test/test_ops.py. one last test specifically set an invalid value to test the exception, and to ignore that we need to import typeguard. And to get a working version of typeguard, we would need to get rid of dependency on tensorflow_addons because it requires a very old version of typeguard
This commit is contained in:
@@ -118,7 +118,7 @@ class TestOps(unittest.TestCase):
|
||||
with self.assertRaises(ValueError): method((2, -3, 0))
|
||||
|
||||
def test_negative_dims_full(self):
|
||||
with self.assertRaises(ValueError): Tensor.full(-3, 2)
|
||||
with self.assertRaises(ValueError): Tensor.full((-3,), 2)
|
||||
with self.assertRaises(ValueError): Tensor.full((2, -3), 4)
|
||||
with self.assertRaises(ValueError): Tensor.full((2, -3, 0), 4)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user