From 9abcb17e9856ce4f622fc5c4ca1f6d99c179c6c7 Mon Sep 17 00:00:00 2001 From: Rodrigo Reichert Date: Thu, 3 Oct 2024 11:46:56 +1000 Subject: [PATCH] Test Case --- python/tests/sbp/test_messages.py | 2 +- .../swiftnav/sbp/imu/test_MsgImuComp.yaml | 27 +++++++++++++++++++ 2 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 spec/tests/yaml/swiftnav/sbp/imu/test_MsgImuComp.yaml diff --git a/python/tests/sbp/test_messages.py b/python/tests/sbp/test_messages.py index 908b664bdf..397245d370 100644 --- a/python/tests/sbp/test_messages.py +++ b/python/tests/sbp/test_messages.py @@ -20,7 +20,7 @@ PYTHON_ROOT = os.path.join(HERE, "..", "..") ROOTPATH = os.path.join(PYTHON_ROOT, "..", "spec", "tests", "yaml") -EXPECTED_MISSING_MESSAGES = 2 +EXPECTED_MISSING_MESSAGES = 1 MESSAGES_WITH_TEST_CASES = set() diff --git a/spec/tests/yaml/swiftnav/sbp/imu/test_MsgImuComp.yaml b/spec/tests/yaml/swiftnav/sbp/imu/test_MsgImuComp.yaml new file mode 100644 index 0000000000..792ae8fa39 --- /dev/null +++ b/spec/tests/yaml/swiftnav/sbp/imu/test_MsgImuComp.yaml @@ -0,0 +1,27 @@ +--- +description: Unit tests for swiftnav.sbp.imu MsgImuCmp +generated_on: 2024-10-03 01:03:00.00 # manually generated +package: sbp.imu +tests: + - msg: + fields: + time: 3221225754 + flags: 206 + acc_comp_x: 96 + acc_comp_y: -33 + acc_comp_z: 4140 + gyr_comp_x: 60 + gyr_comp_y: -304 + gyr_comp_z: -18 + module: sbp.imu + name: MsgImuComp + msg_type: "0x905" + raw_json: '{"time":3221225754,"flags":206,"acc_comp_x":96,"acc_comp_y":-33,"acc_comp_z":4140,"gyr_comp_x":60,"gyr_comp_y":-304,"gyr_comp_z":-18,"preamble":85,"msg_type":2309,"sender":4660,"payload":"GgEAwAAAAADOAGAAAADf////LBAAADwAAADQ/v//7v///w==","crc":22095,"length":34}' + raw_packet: VQUJNBIiGgEAwAAAAADOAGAAAADf////LBAAADwAAADQ/v//7v///09W + sbp: + crc: "0x564f" + length: 34 + msg_type: "0x905" + payload: GgEAwAAAAADOAGAAAADf////LBAAADwAAADQ/v//7v///w== + preamble: "0x55" + sender: "0x1234"