Closed olivier-stasse closed 4 years ago
Is the test actually testing anything, or just printing things for now ?
Is the test actually testing anything, or just printing things for now ?
It is testing the set_parameter and get_parameter member function of the ParameterServer class. The test should check that the string is the same through the two methods.
I can't see where anything is tested. I can only see some print
.
If you do
param_server.setParameter("urdf_model", urdf_rrbot_model_string)
model2_string = param_server.getParameter("urdf_model")
I would expect something like a self.assertEqual(urdf_rrbot_model_string, model2_string)
, somewhere.
One important point. This works only with https://github.com/stack-of-tasks/dynamic-graph/pull/65
I though that this would not work until a new release on dynamic-graph. In this case, it would have been better to wait that before merging, or to explain why would you need to do so, as it will break the CI for all future work on the devel branch.
Using the new Command template in dynamic-graph, this PR implements a simple parameter server using a map of strings (the key is also a std::string).
It allows writing
A unit test is implemented. clang-format has been applied.