fix(failure_injection): keep failure names in sync with FailureInjection.msg (#28376)

unitName()/typeName() lacked the FAILURE_UNIT_DATALINK_*/FAILURE_UNIT_BUS_* units, so `failure can off` was announced as unit "unknown". FailureInjection.msg and VehicleCommand.msg also disagreed on FAILURE_TYPE_DRIFT (MAVLink FAILURE_TYPE 8).

Name every unit and type, add FAILURE_TYPE_DRIFT to both messages and the `failure` console command, and add a test that fails whenever a message constant has no name.
This commit is contained in:
Claudio Chies authored and GitHub committed 2026-09-07 09:16:38 -06:00
1 parent 0fb3847cd9
commit e87918ea2b
4 files changed
+70

No files matched your search

+1
View File
@@ -188,6 +188,7 @@ uint8 FAILURE_TYPE_WRONG = 4
uint8 FAILURE_TYPE_SLOW = 5
uint8 FAILURE_TYPE_DELAYED = 6
uint8 FAILURE_TYPE_INTERMITTENT = 7
uint8 FAILURE_TYPE_DRIFT = 8
# Used as param1 in DO_CHANGE_SPEED command.
uint8 SPEED_TYPE_AIRSPEED = 0