From af50e25647aa5c2051bb09378bc9b2aaaaeb2a07 Mon Sep 17 00:00:00 2001 From: Julian Oes Date: Fri, 23 Jul 2021 06:44:42 +0200 Subject: [PATCH] mavsdk_tests: update to MAVSDK v0.41.0 This required replacing some of the methods which had been deprecated and now removed. --- test/mavsdk_tests/MAVSDK_VERSION | 2 +- test/mavsdk_tests/autopilot_tester.cpp | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/test/mavsdk_tests/MAVSDK_VERSION b/test/mavsdk_tests/MAVSDK_VERSION index 9b0025a785..72a8a6313b 100644 --- a/test/mavsdk_tests/MAVSDK_VERSION +++ b/test/mavsdk_tests/MAVSDK_VERSION @@ -1 +1 @@ -0.40.0 +0.41.0 diff --git a/test/mavsdk_tests/autopilot_tester.cpp b/test/mavsdk_tests/autopilot_tester.cpp index 3e1d55fd80..a80f4d9334 100644 --- a/test/mavsdk_tests/autopilot_tester.cpp +++ b/test/mavsdk_tests/autopilot_tester.cpp @@ -62,9 +62,9 @@ void AutopilotTester::connect(const std::string uri) std::cout << time_str() << "Waiting for system connect" << std::endl; REQUIRE(poll_condition_with_timeout( - [this]() { return _mavsdk.is_connected(); }, std::chrono::seconds(25))); + [this]() { return _mavsdk.systems().size() > 0; }, std::chrono::seconds(25))); - auto &system = _mavsdk.system(); + auto system = _mavsdk.systems().at(0); _action.reset(new Action(system)); _failure.reset(new Failure(system)); @@ -98,7 +98,6 @@ void AutopilotTester::wait_until_ready_local_position_only() (_telemetry->health().is_gyrometer_calibration_ok && _telemetry->health().is_accelerometer_calibration_ok && _telemetry->health().is_magnetometer_calibration_ok && - _telemetry->health().is_level_calibration_ok && _telemetry->health().is_local_position_ok); }, std::chrono::seconds(20))); }