Summary
In this chapter, we explored tools for automatically evaluating the status of a ROS 2 package. First, we discussed automatic unit testing, which allows developers to define a set of test cases that continually verify the correct behavior of the code, even as new features are added. Unit testing can also verify the output of a ROS 2 node when it publishes to topics. ROS 2 is already integrated with the GTest framework, a testing library developed by Google. For more advanced testing strategies, developers can refer to the official GTest documentation, which covers topics such as writing test fixtures and using mocks to simulate dependencies.
Beyond unit testing, another essential approach is CI/CD, which helps ensure that code doesn’t introduce compilation or integration errors. We used GitHub Actions to easily create automatic checks that run when the code is updated. This provides a quick way to inform developers and the community about the repository’s...