Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test_load_controller tests always succeed #1258

Open
christophfroehlich opened this issue Aug 21, 2024 · 1 comment
Open

test_load_controller tests always succeed #1258

christophfroehlich opened this issue Aug 21, 2024 · 1 comment

Comments

@christophfroehlich
Copy link
Contributor

christophfroehlich commented Aug 21, 2024

@christophfroehlich it's probable that they are returning successful even without parameters. That's the only explanation. I could try fixing them tomorrow.

but it throws the exception, and CM::add_controller_impl should return nullptr..

Furthermore, I'm not sure why load_JTC succeeds. it should throw an error without paramaters, but I only see

1: [INFO] [1724185010.487326696] [test_controller_manager]: Subscribing to '/robot_description' topic for robot description.
1: [INFO] [1724185010.487412910] [test_controller_manager]: Loading controller 'test_joint_trajectory_controller'
1: [ERROR] [1724185010.496710000] [test_joint_trajectory_controller]: Unable to start transition 5 from current state shuttingdown: Could not publish transition: publisher's context is invalid, at ./src/rcl/publisher.c:423, at ./src/rcl_lifecycle.c:368
1: [WARN] [1724185010.496722342] [rclcpp_lifecycle]: Shutdown error in destruction of LifecycleNode: final state(unconfigured)
1: [       OK ] TestLoadJointStateController.load_controller (40 ms)

This is not really linked to this PR here. I suggest applying the same changes to admittance_ctrl and range_sensor_broadcaster (the only controllers using a yaml file which are not already addressed) and create a follow-up issue for those false-positive tests.

Originally posted by @christophfroehlich in #1256 (comment)

@christophfroehlich christophfroehlich changed the title test_load_controller tests always return true test_load_controller tests always succeed Aug 21, 2024
@saikishor
Copy link
Member

@christophfroehlich I checked the tests earlier and I saw that some of them are using ASSERT_EQ instead of ASSERT_NE to nullptr. I guess that's why they are passing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants