mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-19 05:03:34 +08:00
Speed up mavsdk sitl tests
This commit is contained in:
@@ -47,9 +47,10 @@ TEST_CASE("Offboard takeoff and land", "[multicopter][offboard][nogps]")
|
||||
tester.wait_until_ready_local_position_only();
|
||||
tester.store_home();
|
||||
tester.arm();
|
||||
tester.offboard_goto(takeoff_position, 0.5f);
|
||||
std::chrono::seconds goto_timeout = std::chrono::seconds(10);
|
||||
tester.offboard_goto(takeoff_position, 0.5f, goto_timeout);
|
||||
tester.offboard_land();
|
||||
tester.wait_until_disarmed();
|
||||
tester.wait_until_disarmed(goto_timeout);
|
||||
tester.check_home_within(0.5f);
|
||||
}
|
||||
|
||||
@@ -64,12 +65,13 @@ TEST_CASE("Offboard position control", "[multicopter][offboard][nogps]")
|
||||
tester.wait_until_ready_local_position_only();
|
||||
tester.store_home();
|
||||
tester.arm();
|
||||
tester.offboard_goto(takeoff_position, 0.5f);
|
||||
tester.offboard_goto(setpoint_1, 1.0f);
|
||||
tester.offboard_goto(setpoint_2, 1.0f);
|
||||
tester.offboard_goto(setpoint_3, 1.0f);
|
||||
tester.offboard_goto(takeoff_position, 0.2f);
|
||||
std::chrono::seconds goto_timeout = std::chrono::seconds(10);
|
||||
tester.offboard_goto(takeoff_position, 0.5f, goto_timeout);
|
||||
tester.offboard_goto(setpoint_1, 1.0f, goto_timeout);
|
||||
tester.offboard_goto(setpoint_2, 1.0f, goto_timeout);
|
||||
tester.offboard_goto(setpoint_3, 1.0f, goto_timeout);
|
||||
tester.offboard_goto(takeoff_position, 0.2f, goto_timeout);
|
||||
tester.offboard_land();
|
||||
tester.wait_until_disarmed();
|
||||
tester.wait_until_disarmed(goto_timeout);
|
||||
tester.check_home_within(1.0f);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user