Skip to content

Commit

Permalink
add test_octomap_server_contact_pr2.test for xacro or xacro.py, see #…
Browse files Browse the repository at this point in the history
  • Loading branch information
k-okada committed Feb 2, 2024
1 parent 55b488d commit ea66520
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 2 deletions.
1 change: 1 addition & 0 deletions jsk_pcl_ros/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -659,6 +659,7 @@ if (CATKIN_ENABLE_TESTING)
if(tf2_eigen_FOUND)
add_rostest(test/test_container_occupancy_detector.test)
endif()
add_rostest(test/test_octomap_server_contact_pr2.test)
endif()
roslaunch_add_file_check(launch/openni_local.launch)
roslaunch_add_file_check(launch/openni2_local.launch)
Expand Down
6 changes: 4 additions & 2 deletions jsk_pcl_ros/sample/sample_octomap_server_contact_pr2.launch
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
<launch>
<arg name="use_gui" default="true" doc="argument to launch rviz" />

<param name="robot_description" command="$(find xacro)/xacro.py '$(find pr2_description)/robots/pr2.urdf.xacro'"/>

<node name="joint_state_publisher" pkg="joint_state_publisher" type="joint_state_publisher">
<param name="use_gui" value="true"/>
<param name="use_gui" value="$(arg use_gui)"/>
</node>

<node name="robot_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher"
Expand Down Expand Up @@ -62,6 +64,6 @@
<node pkg="jsk_pcl_ros" type="test_contact_sensor.py" name="test_contact_sensor"
output="screen" />

<node pkg="rviz" type="rviz" name="rviz"
<node pkg="rviz" type="rviz" name="rviz" if="$(arg use_gui)"
args="-d $(find jsk_pcl_ros)/config/octomap_server_contact_pr2.rviz" />
</launch>
15 changes: 15 additions & 0 deletions jsk_pcl_ros/test/test_octomap_server_contact_pr2.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<launch>
<include file="$(find jsk_pcl_ros)/sample/sample_octomap_server_contact_pr2.launch" >
<arg name="use_gui" value="false" />
</include>

<test test-name="test_octomap_server_contact_pr2"
name="test_octomap_server_contact_pr2"
pkg="jsk_tools" type="test_topic_published.py"
retry="3">
<rosparam>
topic_0: /octomap_binary
timeout_0: 30
</rosparam>
</test>
</launch>

0 comments on commit ea66520

Please sign in to comment.