From 7601ea0ebc1d998a43dd4a2da58cd9b83ce40e09 Mon Sep 17 00:00:00 2001 From: Paul McCarthy <pauldmccarthy@gmail.com> Date: Mon, 15 Jan 2018 13:57:03 +0000 Subject: [PATCH] test no hits case for rayIntersection method --- tests/test_mesh.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/test_mesh.py b/tests/test_mesh.py index 2641c7683..b38ccf8c1 100644 --- a/tests/test_mesh.py +++ b/tests/test_mesh.py @@ -219,7 +219,7 @@ def test_trimesh_no_trimesh(): assert mesh.trimesh() is None locs, tris = mesh.rayIntersection([[0, 0, 0]], [[0, 0, 1]]) assert locs.size == 0 - assert locs.size == 0 + assert tris.size == 0 def test_trimesh(): @@ -253,3 +253,8 @@ def test_rayIntersection(): expected[0, axis] = -1 assert np.all(np.isclose(loc, expected)) + + loc, tri = mesh.rayIntersection([[-1, -1, -1]], [[-1, -1, -1]]) + + assert loc.size == 0 + assert tri.size == 0 -- GitLab