37 RECORD_COMMAND = [
'rosbag',
46 Run rosbag record and send a signal to it after some time. 48 :param test_bag_file_name: bag name for recorded output 49 :param test_signal: signal to send to rosbag 51 test_command = list(RECORD_COMMAND)
52 test_command.insert(4, test_bag_file_name)
54 p = subprocess.Popen(test_command, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
56 time.sleep(SLEEP_TIME_SEC)
57 p.send_signal(test_signal)
def test_signal_cleanup(test_bag_file_name, test_signal)