From da312f9d2c2dab8335fd05c595d299aa32ce8c51 Mon Sep 17 00:00:00 2001 From: iory Date: Tue, 17 May 2022 22:13:30 +0900 Subject: [PATCH] [jsk_tools/audible_warning] Add test --- jsk_tools/CMakeLists.txt | 2 ++ jsk_tools/sample/sample_audible_warning.launch | 4 +++- jsk_tools/test/test_audible_warning.test | 17 +++++++++++++++++ 3 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 jsk_tools/test/test_audible_warning.test diff --git a/jsk_tools/CMakeLists.txt b/jsk_tools/CMakeLists.txt index c1a9e6779..6ae62abfa 100644 --- a/jsk_tools/CMakeLists.txt +++ b/jsk_tools/CMakeLists.txt @@ -27,6 +27,7 @@ endforeach(exec) if (CATKIN_ENABLE_TESTING) find_package(roslint REQUIRED) + roslint_python(src/audible_warning.py) roslint_python(src/jsk_tools/cltool.py) roslint_python(src/test_topic_published.py) roslint_python(src/test_rosparam_set.py) @@ -49,6 +50,7 @@ if (CATKIN_ENABLE_TESTING) # https://github.com/jsk-ros-pkg/jsk_common/pull/1293#issuecomment-164158260 jsk_tools_add_rostest(test/test_rosparam_set.test) endif() + jsk_tools_add_rostest(test/test_audible_warning.test) jsk_tools_add_rostest(test/test_stdout.test) jsk_tools_add_rostest(test/test_rostopic_host_sanity.test) jsk_tools_add_rostest(test/test_sanity_diagnostics.test) diff --git a/jsk_tools/sample/sample_audible_warning.launch b/jsk_tools/sample/sample_audible_warning.launch index 25abf7e2f..df665639c 100644 --- a/jsk_tools/sample/sample_audible_warning.launch +++ b/jsk_tools/sample/sample_audible_warning.launch @@ -2,6 +2,7 @@ + + pkg="sound_play" type="soundplay_node.py" + if="$(arg launch_sound_play)" > diff --git a/jsk_tools/test/test_audible_warning.test b/jsk_tools/test/test_audible_warning.test new file mode 100644 index 000000000..12ff0904e --- /dev/null +++ b/jsk_tools/test/test_audible_warning.test @@ -0,0 +1,17 @@ + + + + + + + + + + topic_0: /sound_play/goal + timeout_0: 10 + + + +