Skip to content

Commit

Permalink
Improve code coverage
Browse files Browse the repository at this point in the history
Signed-off-by: Steve Peters <[email protected]>
  • Loading branch information
scpeters committed Dec 13, 2023
1 parent 756ec54 commit 359875e
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/Link_TEST.cc
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,14 @@ TEST(DOMLink, Construction)
ASSERT_TRUE(link.Density().has_value());
EXPECT_DOUBLE_EQ(density, *link.Density());

EXPECT_EQ(link.AutoInertiaParams(), nullptr);
sdf::ElementPtr autoInertiaParamsElem(new sdf::Element());
autoInertiaParamsElem->SetName("auto_inertia_params");
link.SetAutoInertiaParams(autoInertiaParamsElem);
EXPECT_EQ(link.AutoInertiaParams(), autoInertiaParamsElem);
EXPECT_EQ(link.AutoInertiaParams()->GetName(),
autoInertiaParamsElem->GetName());

EXPECT_EQ(0u, link.CollisionCount());
EXPECT_EQ(nullptr, link.CollisionByIndex(0));
EXPECT_EQ(nullptr, link.CollisionByIndex(1));
Expand Down

0 comments on commit 359875e

Please sign in to comment.