mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-21 22:23:35 +08:00
Commander: switch all state_machine_helper functions to pass by reference
This commit is contained in:
committed by
Daniel Agar
parent
d97fba67e5
commit
531de5c588
@@ -300,10 +300,10 @@ bool StateMachineHelperTest::armingStateTransitionTest()
|
||||
armed.ready_to_arm = test->current_state.ready_to_arm;
|
||||
|
||||
// Attempt transition
|
||||
transition_result_t result = arming_state_transition(&status, safety, test->requested_state, &armed,
|
||||
transition_result_t result = arming_state_transition(status, safety, test->requested_state, armed,
|
||||
true /* enable pre-arm checks */,
|
||||
nullptr /* no mavlink_log_pub */,
|
||||
&status_flags,
|
||||
status_flags,
|
||||
arm_req,
|
||||
2e6, /* 2 seconds after boot, everything should be checked */
|
||||
arm_disarm_reason_t::UNIT_TEST);
|
||||
@@ -517,7 +517,7 @@ bool StateMachineHelperTest::mainStateTransitionTest()
|
||||
|
||||
// Attempt transition
|
||||
transition_result_t result = main_state_transition(current_vehicle_status, test->to_state, current_status_flags,
|
||||
¤t_commander_state);
|
||||
current_commander_state);
|
||||
|
||||
// Validate result of transition
|
||||
ut_compare(test->assertMsg, test->expected_transition_result, result);
|
||||
|
||||
Reference in New Issue
Block a user