Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Jun 17, 2024
1 parent e76f28a commit 4edc0ed
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 13 deletions.
4 changes: 2 additions & 2 deletions include/mc_rtc/gui/Arrow.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ struct ArrowROImpl : public Element
}

/** Invalid element */
ArrowROImpl(){};
ArrowROImpl() {};

constexpr static size_t write_size() { return Element::write_size() + 3 + ArrowConfig::write_size(); }

Expand Down Expand Up @@ -72,7 +72,7 @@ struct ArrowImpl : public ArrowROImpl<GetStart, GetEnd>
}

/** Invalid element */
ArrowImpl(){};
ArrowImpl() {};

void write(mc_rtc::MessagePackBuilder & builder) { ArrowROImpl<GetStart, GetEnd>::write(builder, false); }

Expand Down
24 changes: 13 additions & 11 deletions tests/test_mc_rbdyn.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,13 @@ BOOST_AUTO_TEST_CASE(TestRobotPosWVelWAccW)

auto checkVelocity = [](const sva::MotionVecd & actual, const sva::MotionVecd & refVal)
{
BOOST_CHECK_MESSAGE(actual.vector().isApprox(refVal.vector()),
"Error in Robot::velW" << "\nExpected:" << "\nangular:" << refVal.angular().transpose()
<< "\nlinear :" << refVal.linear().transpose()
<< "\nGot:" << "\nangular:" << actual.angular().transpose()
<< "\nlinear :" << actual.linear().transpose());
BOOST_CHECK_MESSAGE(actual.vector().isApprox(refVal.vector()), "Error in Robot::velW"
<< "\nExpected:"
<< "\nangular:" << refVal.angular().transpose()
<< "\nlinear :" << refVal.linear().transpose()
<< "\nGot:"
<< "\nangular:" << actual.angular().transpose()
<< "\nlinear :" << actual.linear().transpose());
};

for(int i = 0; i < 100; ++i)
Expand Down Expand Up @@ -151,9 +153,9 @@ BOOST_AUTO_TEST_CASE(TestRobotZMPSimple)

auto zmpIdeal = X_0_ls.translation();
auto zmpComputed = robot.zmp(sensorNames, Eigen::Vector3d::Zero(), {0., 0., 1.});
BOOST_CHECK_MESSAGE(zmpComputed.isApprox(zmpIdeal, 1e-10),
"Error in Robot::zmp computation with leftFootRatio=" << "\nExpected: " << zmpIdeal.transpose()
<< "\nGot: " << zmpComputed.transpose());
BOOST_CHECK_MESSAGE(zmpComputed.isApprox(zmpIdeal, 1e-10), "Error in Robot::zmp computation with leftFootRatio="
<< "\nExpected: " << zmpIdeal.transpose()
<< "\nGot: " << zmpComputed.transpose());
}

{
Expand All @@ -167,9 +169,9 @@ BOOST_AUTO_TEST_CASE(TestRobotZMPSimple)

auto zmpIdeal = X_0_rs.translation();
auto zmpComputed = robot.zmp(sensorNames, Eigen::Vector3d::Zero(), {0., 0., 1.});
BOOST_CHECK_MESSAGE(zmpComputed.isApprox(zmpIdeal, 1e-10),
"Error in Robot::zmp computation with leftFootRatio=" << "\nExpected: " << zmpIdeal.transpose()
<< "\nGot: " << zmpComputed.transpose());
BOOST_CHECK_MESSAGE(zmpComputed.isApprox(zmpIdeal, 1e-10), "Error in Robot::zmp computation with leftFootRatio="
<< "\nExpected: " << zmpIdeal.transpose()
<< "\nGot: " << zmpComputed.transpose());
}

{ // checks that zmp throws if used with null force
Expand Down

0 comments on commit 4edc0ed

Please sign in to comment.