From 3323be325c558ecc5ded7bc7fab36c36a13083b4 Mon Sep 17 00:00:00 2001 From: Christoph Froehlich Date: Fri, 26 Jul 2024 21:21:56 +0000 Subject: [PATCH] Revert "Activate assertExitCodes tests" This reverts commit fe28c67cb2625fbff37bd4417af8b131e5f5ee4c. --- example_1/test/test_rrbot_launch.py | 15 ++++++++------- example_10/test/test_rrbot_launch.py | 15 ++++++++------- example_11/test/test_carlikebot_launch.py | 15 ++++++++------- example_12/test/test_rrbot_launch.py | 15 ++++++++------- ...edback_sensors_for_position_feedback_launch.py | 1 - .../test/test_multi_controller_manager_launch.py | 15 ++++++++------- example_15/test/test_rrbot_namespace_launch.py | 15 ++++++++------- example_2/test/test_diffbot_launch.py | 15 ++++++++------- .../test_rrbot_system_multi_interface_launch.py | 15 ++++++++------- .../test/test_rrbot_system_with_sensor_launch.py | 15 ++++++++------- ...st_rrbot_system_with_external_sensor_launch.py | 15 ++++++++------- .../test/test_rrbot_modular_actuators_launch.py | 15 ++++++++------- example_7/test/test_r6bot_controller_launch.py | 15 ++++++++------- ...t_transmissions_system_position_only_launch.py | 15 ++++++++------- example_9/test/test_rrbot_launch.py | 15 ++++++++------- 15 files changed, 112 insertions(+), 99 deletions(-) diff --git a/example_1/test/test_rrbot_launch.py b/example_1/test/test_rrbot_launch.py index 3ac143b9b..496f44fc4 100644 --- a/example_1/test/test_rrbot_launch.py +++ b/example_1/test/test_rrbot_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -91,10 +91,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_10/test/test_rrbot_launch.py b/example_10/test/test_rrbot_launch.py index bb4bb8b68..45c8227d1 100644 --- a/example_10/test/test_rrbot_launch.py +++ b/example_10/test/test_rrbot_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -96,10 +96,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_11/test/test_carlikebot_launch.py b/example_11/test/test_carlikebot_launch.py index 3914b4a2f..e0e8827a3 100644 --- a/example_11/test/test_carlikebot_launch.py +++ b/example_11/test/test_carlikebot_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -97,10 +97,11 @@ def test_check_if_msgs_published(self): ) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_12/test/test_rrbot_launch.py b/example_12/test/test_rrbot_launch.py index 0200668c5..f88930e16 100644 --- a/example_12/test/test_rrbot_launch.py +++ b/example_12/test/test_rrbot_launch.py @@ -40,7 +40,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -141,10 +141,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_14/test/test_rrbot_modular_actuators_without_feedback_sensors_for_position_feedback_launch.py b/example_14/test/test_rrbot_modular_actuators_without_feedback_sensors_for_position_feedback_launch.py index d42faf68a..fab0cf4be 100644 --- a/example_14/test/test_rrbot_modular_actuators_without_feedback_sensors_for_position_feedback_launch.py +++ b/example_14/test/test_rrbot_modular_actuators_without_feedback_sensors_for_position_feedback_launch.py @@ -95,7 +95,6 @@ def test_check_if_msgs_published(self): # TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore -# see https://github.com/ros-controls/ros2_control_demos/issues/542 # @launch_testing.post_shutdown_test() # # These tests are run after the processes in generate_test_description() have shutdown. # class TestDescriptionCraneShutdown(unittest.TestCase): diff --git a/example_15/test/test_multi_controller_manager_launch.py b/example_15/test/test_multi_controller_manager_launch.py index d8e7c054f..dac496013 100644 --- a/example_15/test/test_multi_controller_manager_launch.py +++ b/example_15/test/test_multi_controller_manager_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node @@ -96,10 +96,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/rrbot_2/joint_states", ["rrbot_2_joint1", "rrbot_2_joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_15/test/test_rrbot_namespace_launch.py b/example_15/test/test_rrbot_namespace_launch.py index 3ab55aa9c..cfb0f8de6 100644 --- a/example_15/test/test_rrbot_namespace_launch.py +++ b/example_15/test/test_rrbot_namespace_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node @@ -95,10 +95,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/rrbot/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_2/test/test_diffbot_launch.py b/example_2/test/test_diffbot_launch.py index 5c742fb7f..94477b462 100644 --- a/example_2/test/test_diffbot_launch.py +++ b/example_2/test/test_diffbot_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -91,10 +91,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["left_wheel_joint", "right_wheel_joint"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_3/test/test_rrbot_system_multi_interface_launch.py b/example_3/test/test_rrbot_system_multi_interface_launch.py index 191284309..a388e5e26 100644 --- a/example_3/test/test_rrbot_system_multi_interface_launch.py +++ b/example_3/test/test_rrbot_system_multi_interface_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -91,10 +91,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_4/test/test_rrbot_system_with_sensor_launch.py b/example_4/test/test_rrbot_system_with_sensor_launch.py index d4425e091..e74009300 100644 --- a/example_4/test/test_rrbot_system_with_sensor_launch.py +++ b/example_4/test/test_rrbot_system_with_sensor_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -91,10 +91,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_5/test/test_rrbot_system_with_external_sensor_launch.py b/example_5/test/test_rrbot_system_with_external_sensor_launch.py index fa2edec4f..14b38614f 100644 --- a/example_5/test/test_rrbot_system_with_external_sensor_launch.py +++ b/example_5/test/test_rrbot_system_with_external_sensor_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -91,10 +91,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_6/test/test_rrbot_modular_actuators_launch.py b/example_6/test/test_rrbot_modular_actuators_launch.py index c9909b87c..36394774e 100644 --- a/example_6/test/test_rrbot_modular_actuators_launch.py +++ b/example_6/test/test_rrbot_modular_actuators_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -91,10 +91,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_7/test/test_r6bot_controller_launch.py b/example_7/test/test_r6bot_controller_launch.py index 200720d55..7d2c546b7 100644 --- a/example_7/test/test_r6bot_controller_launch.py +++ b/example_7/test/test_r6bot_controller_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -93,10 +93,11 @@ def test_check_if_msgs_published(self): ) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_8/test/test_rrbot_transmissions_system_position_only_launch.py b/example_8/test/test_rrbot_transmissions_system_position_only_launch.py index 3ce0353a4..26ee20f8c 100644 --- a/example_8/test/test_rrbot_transmissions_system_position_only_launch.py +++ b/example_8/test/test_rrbot_transmissions_system_position_only_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -91,10 +91,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info) diff --git a/example_9/test/test_rrbot_launch.py b/example_9/test/test_rrbot_launch.py index 0092d6bc2..a287535d9 100644 --- a/example_9/test/test_rrbot_launch.py +++ b/example_9/test/test_rrbot_launch.py @@ -39,7 +39,7 @@ from launch.launch_description_sources import PythonLaunchDescriptionSource from launch_testing.actions import ReadyToTest -import launch_testing.markers +# import launch_testing.markers import rclpy from rclpy.node import Node from ros2_control_demo_testing.test_utils import check_controllers_running, check_if_js_published @@ -91,10 +91,11 @@ def test_check_if_msgs_published(self): check_if_js_published("/joint_states", ["joint1", "joint2"]) -@launch_testing.post_shutdown_test() -# These tests are run after the processes in generate_test_description() have shutdown. -class TestDescriptionCraneShutdown(unittest.TestCase): +# TODO(anyone): enable this if shutdown of ros2_control_node does not fail anymore +# @launch_testing.post_shutdown_test() +# # These tests are run after the processes in generate_test_description() have shutdown. +# class TestDescriptionCraneShutdown(unittest.TestCase): - def test_exit_codes(self, proc_info): - """Check if the processes exited normally.""" - launch_testing.asserts.assertExitCodes(proc_info) +# def test_exit_codes(self, proc_info): +# """Check if the processes exited normally.""" +# launch_testing.asserts.assertExitCodes(proc_info)