0
$\begingroup$

Rosanswers logo

I am wondering how I could automate the build of my unit tests.

Because right now I have to call make test in every package.
But I would like to automate this, to build for every package that has a test in it.

Something like a rosmake command for testing would be ideal.
Or can I add something to the makefile, so rosmake will also build the test?


Originally posted by madmax on ROS Answers with karma: 496 on 2013-06-05

Post score: 1

$\endgroup$

2 Answers 2

0
$\begingroup$

Rosanswers logo

Ok, I should have searched for rosmake options. ;-)
There is a command rosmake [PACKAGE] -t that builds and tests the package.
But it calls make test only for the package specified and not for the packages it depends on...


Originally posted by madmax with karma: 496 on 2013-06-05

This answer was ACCEPTED on the original site

Post score: 1

$\endgroup$
0
$\begingroup$

Rosanswers logo

I reached the same conclusion: there is, AFAIK, no way of building and running tests for all package dependencies of a given package. 'rosmake -t foo' will only compile and run the tests for package 'foo', but not for its dependencies.

I wrote a small script to do that. This script calls 'make test' in all dependencies of the given package and presents the results in a fancy way. Available here, hope it helps! https://sites.google.com/site/rameyarnaud/misc/ros/ros-unit-tests-compilation


Originally posted by anonymous2054 with karma: 101 on 2013-10-07

This answer was NOT ACCEPTED on the original site

Post score: 2

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.