test topic with gtest
hi, i wanna test a topic, what it actually publish, and when changing something, what the topic then publishes. My problem is, that i need to declare a callback function in the subscribe() member function of the nodeHandle.
What is the "best" way to handle that? I mean, in the main TEST() function a loop over a global variable till the callback has changed this global var, then end the main TEST() function?
i know ros.org/wiki/rostest/Nodes but its written in python, and i wanna write it in c++, perhaps someone knows a tutorial?
thanks flo