From 2c6399c6fb6ceba0fd5ebe6f61cb26732bb384a0 Mon Sep 17 00:00:00 2001 From: bpapaspyros Date: Thu, 5 Dec 2024 15:37:37 +0100 Subject: [PATCH] test: expand tests to check uninitialized node exceptions --- source/modulo_controllers/test/test_controller_interface.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/source/modulo_controllers/test/test_controller_interface.cpp b/source/modulo_controllers/test/test_controller_interface.cpp index 0ee27fe8..5f3078e1 100644 --- a/source/modulo_controllers/test/test_controller_interface.cpp +++ b/source/modulo_controllers/test/test_controller_interface.cpp @@ -220,6 +220,11 @@ TYPED_TEST_P(ControllerInterfaceTest, OutputTest) { } TYPED_TEST_P(ControllerInterfaceTest, TF) { + EXPECT_THROW(this->interface_->add_tf_broadcaster(), modulo_core::exceptions::CoreException); + EXPECT_THROW(this->interface_->add_static_tf_broadcaster(), modulo_core::exceptions::CoreException); + EXPECT_THROW(this->interface_->add_tf_listener(), modulo_core::exceptions::CoreException); + auto send_early_tf = state_representation::CartesianPose::Random("test", "world"); + EXPECT_THROW(this->interface_->send_transform(send_early_tf), modulo_core::exceptions::CoreException); this->init(); this->interface_->add_tf_broadcaster(); this->interface_->add_static_tf_broadcaster();