add_rostest(.. DEPENDECIES..) / catkin tools build/test issues
naveedhd opened this issue · comments
I experienced that If I changed my test and ran tests (with catkin tools) it did not build my test and ran with the previous one. But If I do catkin b
and then catkin run_tests
, that works as expected ( builds the test executable and run against it). Is this normal?
Other way to solve was to add depencency to executable in add_rostest
eg:
from add_rostest(catch_test.test)
to add_rostest(catch_test.test DEPEDENCIES catch_test)
Is this the expected behavior?
If adding DEPENDECIES tag is recommended, would it be a good idea to include that within catch_add_rostest_node
(maybe rename to catch_add_rostest
) cmake function? (like gtest)
Thanks for the report, this is indeed a bug (or at least confusing). I have a fix in #9, which does the same as rostest
does for the gtest-based tests: introduce a dependency from the generic tests
target to the new node.
It works on my local packages. If it's not too much trouble, could you please confirm #9 also fixes the problem on your side?
Tested #9 and that indeed solves the issue.
Thanks for the confirmation!