From 63631e262cf862d2e0572283771b58b4216c137f Mon Sep 17 00:00:00 2001 From: Andrei Litvin Date: Thu, 5 Sep 2024 20:14:40 -0400 Subject: [PATCH] Better error message on service not found --- src/python_testing/TC_ICDM_5_1.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/python_testing/TC_ICDM_5_1.py b/src/python_testing/TC_ICDM_5_1.py index e0417ff52bf1dc..16da6e20d5c9e7 100644 --- a/src/python_testing/TC_ICDM_5_1.py +++ b/src/python_testing/TC_ICDM_5_1.py @@ -81,6 +81,9 @@ async def _get_icd_txt_record(self) -> OperatingModeEnum: compressed_fabric_id=self.default_controller.GetCompressedFabricId(), log_output=True, discovery_timeout_sec=240) + asserts.assert_is_not_none( + service, f"Failed to get operational node service information for {self.dut_node_id} on {self.default_controller.GetCompressedFabricId()}") + icdTxtRecord = OperatingModeEnum(int(service.txt_record['ICD'])) if icdTxtRecord.value != int(service.txt_record['ICD']): raise AttributeError(f'Not a known ICD type: {service.txt_record["ICD"]}')