summaryrefslogtreecommitdiffhomepage
path: root/editor/tests
diff options
context:
space:
mode:
Diffstat (limited to 'editor/tests')
-rw-r--r--editor/tests/raycast-test.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/editor/tests/raycast-test.cpp b/editor/tests/raycast-test.cpp
index 24f0fde2..ec0dc5ec 100644
--- a/editor/tests/raycast-test.cpp
+++ b/editor/tests/raycast-test.cpp
@@ -225,7 +225,7 @@ struct raycast_test : base_test
auto size = Vector2ui(Math::round(Math::abs(v)));
const auto half = Vector2i(v*.5);
- auto nsteps = (uint32_t)Math::ceil(Math::abs(vec[long_axis] / step));
+ auto nsteps = (uint32_t)Math::max(1., Math::ceil(Math::abs(vec[long_axis] / step)));
result.path.clear();
result.path.reserve(nsteps);