From 8d819f692de39d3d0199b7cfe1e33df91285f43d Mon Sep 17 00:00:00 2001 From: Wessel Bruinsma Date: Wed, 25 Aug 2021 11:54:54 +0200 Subject: [PATCH] Actually fix CI --- lab/shaping.py | 5 +---- tests/test_shaping.py | 2 ++ 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/lab/shaping.py b/lab/shaping.py index 5061e6e..3517539 100644 --- a/lab/shaping.py +++ b/lab/shaping.py @@ -104,10 +104,7 @@ def shape(a, dim: Int, *dims: Int): a_shape = B.shape(a) subshape = tuple(a_shape[i] for i in dims) if LazyShapes.enabled: - # For some reason, CI does not count this line as tested. It, however, is - # certainly tested by `test_shaping.py::test_subshape`... - # TODO: Fix this. - return Shape(*subshape) # pragma: no cover + return Shape(*subshape) else: return subshape diff --git a/tests/test_shaping.py b/tests/test_shaping.py index 4f7ceee..d5f478c 100644 --- a/tests/test_shaping.py +++ b/tests/test_shaping.py @@ -260,7 +260,9 @@ def test_take_tf(check_lazy_shapes): a = Matrix(3, 4, 5) ref = Tensor(3) approx(B.take(a.tf(), ref.tf() > 0), B.take(a.np(), ref.np() > 0)) + approx(B.take(a.tf(), ref.np() > 0), B.take(a.np(), ref.np() > 0)) approx(B.take(a.tf(), B.range(tf.int64, 2)), B.take(a.np(), B.range(2))) + approx(B.take(a.tf(), B.range(np.int64, 2)), B.take(a.np(), B.range(2))) def test_submatrix(check_lazy_shapes):