Skip to content

Commit

Permalink
Merge pull request #60 from bulwahn/indigo-devel
Browse files Browse the repository at this point in the history
make rostest in CMakeLists optional (ros/rosdistro#3010)
  • Loading branch information
trainman419 committed Apr 25, 2017
2 parents 0a103a4 + aa8052e commit 876fc01
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion diagnostic_aggregator/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 2.8.3)
project(diagnostic_aggregator)

# Load catkin and all dependencies required for this package
find_package(catkin REQUIRED diagnostic_msgs pluginlib roscpp rospy rostest xmlrpcpp bondcpp)
find_package(catkin REQUIRED diagnostic_msgs pluginlib roscpp rospy xmlrpcpp bondcpp)
catkin_package(DEPENDS diagnostic_msgs pluginlib roscpp rospy xmlrpcpp bondcpp bondpy
INCLUDE_DIRS include
LIBRARIES ${PROJECT_NAME})
Expand Down Expand Up @@ -46,6 +46,7 @@ add_executable(analyzer_loader test/analyzer_loader.cpp
target_link_libraries(analyzer_loader diagnostic_aggregator)

if(CATKIN_ENABLE_TESTING)
find_package(rostest REQUIRED)
add_rostest(test/launch/test_agg.launch)
add_rostest(test/launch/test_add_agg.launch)

Expand Down
3 changes: 2 additions & 1 deletion diagnostic_analysis/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@ cmake_minimum_required(VERSION 2.8.3)
project(diagnostic_analysis)

# Load catkin and all dependencies required for this package
find_package(catkin REQUIRED diagnostic_msgs rosbag roslib rostest)
find_package(catkin REQUIRED diagnostic_msgs rosbag roslib)

catkin_package(DEPENDS diagnostic_msgs rosbag roslib)

if(CATKIN_ENABLE_TESTING)
find_package(rostest REQUIRED)
catkin_add_nosetests(test/bag_csv_test.py)
endif()

Expand Down
3 changes: 2 additions & 1 deletion diagnostic_updater/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 2.8.3)
project(diagnostic_updater)

# Load catkin and all dependencies required for this package
find_package(catkin REQUIRED diagnostic_msgs roscpp rostest std_msgs)
find_package(catkin REQUIRED diagnostic_msgs roscpp std_msgs)

catkin_python_setup()

Expand All @@ -15,6 +15,7 @@ add_executable(example src/example.cpp)
target_link_libraries(example ${catkin_LIBRARIES})

if(CATKIN_ENABLE_TESTING)
find_package(rostest REQUIRED)
add_rostest_gtest(diagnostic_updater_test test/diagnostic_updater_test.xml test/diagnostic_updater_test.cpp)
add_rostest(test/diagnostic_updater_fast_test.xml)
target_link_libraries(diagnostic_updater_test ${catkin_LIBRARIES})
Expand Down

0 comments on commit 876fc01

Please sign in to comment.