From 7dda87fd4407e6545efec99af945ab7e2d9f7c52 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Tue, 29 Oct 2019 11:50:24 +1100 Subject: [PATCH] autotest: assert ArduPilot announces compass cal capability --- Tools/autotest/apmrover2.py | 2 +- Tools/autotest/balancebot.py | 2 +- Tools/autotest/common.py | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Tools/autotest/apmrover2.py b/Tools/autotest/apmrover2.py index 7e4b5c7a95..caa2ffba4f 100644 --- a/Tools/autotest/apmrover2.py +++ b/Tools/autotest/apmrover2.py @@ -4792,7 +4792,7 @@ Brakes have negligible effect (with=%0.2fm without=%0.2fm delta=%0.2fm) ("GetCapabilities", "Get Capabilities", - self.do_get_autopilot_capabilities), + self.test_get_autopilot_capabilities), ("DO_SET_MODE", "Set mode via MAV_COMMAND_DO_SET_MODE", diff --git a/Tools/autotest/balancebot.py b/Tools/autotest/balancebot.py index d5d4f81bda..7ff5cd3939 100644 --- a/Tools/autotest/balancebot.py +++ b/Tools/autotest/balancebot.py @@ -117,7 +117,7 @@ inherit Rover's tests!''' ("GetCapabilities", "Get Capabilities", - self.do_get_autopilot_capabilities), + self.test_get_autopilot_capabilities), ("DO_SET_MODE", "Set mode via MAV_COMMAND_DO_SET_MODE", diff --git a/Tools/autotest/common.py b/Tools/autotest/common.py index 00dcba39a2..6ab8d04723 100644 --- a/Tools/autotest/common.py +++ b/Tools/autotest/common.py @@ -1548,8 +1548,9 @@ class AutoTest(ABC): raise NotAchievedException("Did not get AUTOPILOT_VERSION") return m.capabilities - def do_get_autopilot_capabilities(self): + def test_get_autopilot_capabilities(self): self.assert_capability(mavutil.mavlink.MAV_PROTOCOL_CAPABILITY_PARAM_FLOAT) + self.assert_capability(mavutil.mavlink.MAV_PROTOCOL_CAPABILITY_COMPASS_CALIBRATION) def get_mode_from_mode_mapping(self, mode): """Validate and return the mode number from a string or int."""