diff --git a/launch_testing_ros/test/examples/set_param_launch_test.py b/launch_testing_ros/test/examples/set_param_launch_test.py index e8b2da70..4bd7cd57 100644 --- a/launch_testing_ros/test/examples/set_param_launch_test.py +++ b/launch_testing_ros/test/examples/set_param_launch_test.py @@ -61,9 +61,11 @@ def __init__(self, name='test_node'): super().__init__(name) def set_parameter(self, state=True, timeout=5.0): - parameters = [rclpy.Parameter('demo_parameter_1', value=state).to_parameter_msg()] + parameters = [rclpy.Parameter( + 'demo_parameter_1', value=state).to_parameter_msg()] - client = self.create_client(SetParameters, 'demo_node_1/set_parameters') + client = self.create_client( + SetParameters, 'demo_node_1/set_parameters') ready = client.wait_for_service(timeout_sec=timeout) if not ready: raise RuntimeError('Wait for service timed out') @@ -71,7 +73,7 @@ def set_parameter(self, state=True, timeout=5.0): request = SetParameters.Request() request.parameters = parameters future = client.call_async(request) - rclpy.spin_until_future_complete(self, future, timeout_sec=timeout) + rclpy.spin_until_complete(self, future, timeout_sec=timeout) assert future.done(), 'Client request timed out'