* Use valid clock in case of issue in rcl_timer_init (#795)
* Use valid clock in case of issue
Signed-off-by: Stephen Brawner <brawner@gmail.com>
* Cleanup
Signed-off-by: Stephen Brawner <brawner@gmail.com>
Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
* Store reference to rcl_clock_t instead of copy (#797)
rcl_clock_t can't be trivially copied because adding or removing clock
jump callbacks to a copy will free the pointer held by the original
instance.
Signed-off-by: Shane Loretz<sloretz@openrobotics.org>
Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
Co-authored-by: brawner <brawner@gmail.com>
* Fix missing call fini() for lifecycle_transition and node in test_rcl_lifecycle
Signed-off-by: Barry Xu <barry.xu@sony.com>
* Fix error overwritten while allocator is Nullptr.
Signed-off-by: Barry Xu <barry.xu@sony.com>
* Optimize used variables
Signed-off-by: Barry Xu <barry.xu@sony.com>
Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
Co-authored-by: Barry Xu <barry.xu@sony.com>
* Add bug fix for rcl_node_options_copy
If copy source has options->arguments.impl==NULL
this will cause problem when calling fini
on options dst
* Add test case for bug fix
* Return error when passing not init object
* Remove unexpected usage test
* Init options with non empty arguments
Signed-off-by: Jorge Perez <jjperez@ekumenlabs.com>
* Add tests for node_options usage
* Add tests for copying options arguments
* Add bad argument tests for wait sets
* Add tests for wait_set_get_allocator function
* Add test for rcl_take_response function
* Change take_request to match take_response without info
* Change specific test for sequence_number
* Add tests for client take failed
* Remove tests already done in nominal setup
* Add bad arguments tests
* Add test for init returning BAD_ALLOC
* Add test for client get_options
* Add test for already init client
* Add bad argument tests
* Add basic test get_default_domain_id
* Add test for rmw to rcl return code function
* Add test for get_localhost_only
* Add tests for localhost expected usage
* Address peer review comments
* Add test for env variable leading to ULONG_MAX
* Change return values to enum in test
* Fix rcl_get_localhost_only return value
* Address peer review comments
* Add unexpected value to get_localhost
* Add reset_rcl_error after expected fails
Signed-off-by: Jorge Perez <jjperez@ekumenlabs.com>
* Check for case RMW_LOCALHOST_ONLY_DISABLED in init_options
* Take init value from node context
* Convert enum variable to boolean
* Remove extra check
* Remove not needed reference and dereference
* Change rcl_get_localhost_only to match signature
* Add parenthesis to make clearer precedence
Signed-off-by: Jorge Perez <jjperez@ekumenlabs.com>
* Add action_server validity check, and remove dead code
Signed-off-by: Stephen Brawner <brawner@gmail.com>
* Increase test coverage of rcl_action
Signed-off-by: Stephen Brawner <brawner@gmail.com>
* Reorganizing impl structs into private header
Signed-off-by: Stephen Brawner <brawner@gmail.com>
* Addressing PR Feedback
Signed-off-by: Stephen Brawner <brawner@gmail.com>
* Addressing memory error and PR feedback
Signed-off-by: Stephen Brawner <brawner@gmail.com>
Co-authored-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
* transition start and goal states can be null
Signed-off-by: Karsten Knese <karsten@openrobotics.org>
* correct tests
Signed-off-by: Karsten Knese <karsten@openrobotics.org>
* Cleanup and address issues in parser.c
Signed-off-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
squash! Cleanup and address issues in parser.c
* Increase test coverage of parser
Signed-off-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
* PR Fixup
Signed-off-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
* PR Fixup
Signed-off-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
Co-authored-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
* Increase test coverage and add more safety checks
Signed-off-by: Stephen Brawner <brawner@gmail.com>
* More coverage
Signed-off-by: Stephen Brawner <brawner@gmail.com>
* Concatenating error messages
Signed-off-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
* PR Fixup
Signed-off-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
* Forgot a
Signed-off-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
* PR Fixup
Signed-off-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
* Moving var to top
Signed-off-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
Co-authored-by: Stephen Brawner <stephenbrawner@verbsurgical.com>
* warn about unused return value for set_logger_level
Signed-off-by: Dirk Thomas <dirk-thomas@users.noreply.github.com>
* revert change of RCL_UNUSED macro
Signed-off-by: Dirk Thomas <dirk-thomas@users.noreply.github.com>
Debugging #611 these timeouts were so long that the overall test timeout was being triggered before these internal timeouts were triggered.
1000 retries at 100ms -> 10 seconds each. I cut it down to 1 second for each to establish the connection.
Signed-off-by: Tully Foote <tfoote@osrfoundation.org>
* Add tests for time.c module
* Add test for function rcl_timer_clock
* Fix linter style issues
* Add test for rcl_timer_call
* Add callback test and improve call test
* Add fixture class to reuse timer init/fini code
* Change error code returned to match function being tested
* Add tests for timer_reset function
* Add tests for exchange_callback function
* Add null parameter test for get guard condition
* Add allocator testing tools auxiliar file
* Add tests for failing ini/fini conditions
* Add test for get_period function
* Add test to get_time_since_last_call
* Remove comment related to variable names
* Fix return value on test case for fini clock
* Address peer review comments
* Fix CLang warning, replacing NULL with false
Signed-off-by: Jorge Perez <jjperez@ekumenlabs.com>
* initial draft of the quality declaration
* Reformat to match REP-2004 template
* Fix README.md files accordingly for the rcl package
* Fix minor typos
* Fix minor issues according to peer review
* Address peer review comments
* Improve current state Feature documentation
Signed-off-by: Jorge Perez <jjperez@ekumenlabs.com>
Co-authored-by: William Woodall <william@osrfoundation.org>