Skip to content

Commit

Permalink
All topics testing1
Browse files Browse the repository at this point in the history
  • Loading branch information
PrasRsRos committed Sep 11, 2023
1 parent 0446d7c commit 5f7ec20
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion realsense2_camera/test/utils/pytest_rs_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -830,6 +830,7 @@ def spin_for_data(self,themes, timeout=5.0):
flag = False
data_not_expected = [i for i in themes if (i["expected_data_chunks"]) == 0]
start = time.time()
msg = "Unexpected error in spin_for_data"
while (time.time() - start) < timeout:
rclpy.spin_once(self.node, timeout_sec=1)
debug_print('Spun once... ' )
Expand All @@ -847,9 +848,10 @@ def spin_for_data(self,themes, timeout=5.0):
if data_not_expected == False:
print("Timed out waiting for", timeout, "seconds" )
return False, "run_test timedout"
flag = True
if flag:
return flag,""
return flag,"Unexpected error in spin_for_data"
return flag,msg

def spin_for_time(self,wait_time):
start = time.time()
Expand Down

0 comments on commit 5f7ec20

Please sign in to comment.