From c550e3d8aaa90b231e83fd2ee6746c6f7e3d8ed4 Mon Sep 17 00:00:00 2001 From: "Addisu Z. Taddese" Date: Tue, 26 Sep 2023 22:31:26 -0500 Subject: [PATCH] Add a failing test showing behavior when mesh calculator callback is not set Signed-off-by: Addisu Z. Taddese --- test/integration/root_dom.cc | 10 ++++++++++ test/sdf/mesh_auto_inertial.sdf | 17 +++++++++++++++++ 2 files changed, 27 insertions(+) create mode 100644 test/sdf/mesh_auto_inertial.sdf diff --git a/test/integration/root_dom.cc b/test/integration/root_dom.cc index 69d682dd8..3b5d7c0ca 100644 --- a/test/integration/root_dom.cc +++ b/test/integration/root_dom.cc @@ -300,3 +300,13 @@ TEST(DOMRoot, CreateMulipleWorlds) testFunc(root); testFunc(root2); } + +///////////////////////////////////////////////// +TEST(DOMRoot, LoadWithoutMeshAutoInertialCalculator) +{ + const std::string testFile = + sdf::testing::TestFile("sdf", "mesh_auto_inertial.sdf"); + sdf::Root root; + sdf::Errors errors = root.Load(testFile); + EXPECT_TRUE(errors.empty()) << errors; +} diff --git a/test/sdf/mesh_auto_inertial.sdf b/test/sdf/mesh_auto_inertial.sdf new file mode 100644 index 000000000..ece976a41 --- /dev/null +++ b/test/sdf/mesh_auto_inertial.sdf @@ -0,0 +1,17 @@ + + + + + + + + + + box.dae + + + + + + +