From 778988ec65a73c185b40b3b99945b68338f0c69b Mon Sep 17 00:00:00 2001 From: Ryan Date: Fri, 29 Dec 2023 21:41:15 -0500 Subject: [PATCH] Test curvatureToPoint when zero curvature --- test/test/Geometry/PoseTest.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/test/Geometry/PoseTest.cpp b/test/test/Geometry/PoseTest.cpp index 392449a..bda8bd8 100644 --- a/test/test/Geometry/PoseTest.cpp +++ b/test/test/Geometry/PoseTest.cpp @@ -146,4 +146,11 @@ TEST(PoseTest, curvatureToPoint) { rz::Translation target(2_m, 4_m); EXPECT_NEAR(rz::curvatureToPoint(pose, target).convert(radpm), -0.5, EPSILON); +} + +TEST(PoseTest, curvatureToPointZero) { + rz::Pose pose(rz::Translation(4_m, 2_m), 0_deg); + rz::Translation target(6_m, 2_m); + + EXPECT_NEAR(rz::curvatureToPoint(pose, target).convert(radpm), 0, 0); } \ No newline at end of file