ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

I ran into a variant of this problem. In my case, the first test would print ROS_INFO messages, but subsequent tests wouldn't. I found it necessary to call ros::init and other ROS calls AFTER calling InitGoogleTests. I updated the ROS gtest wiki page at http://wiki.ros.org/gtest to show an example of initializing ROS after initializing gtest. I hope this helps.