diff --git a/src/python_testing/TC_TIMESYNC_2_2.py b/src/python_testing/TC_TIMESYNC_2_2.py index 72b9d0978e65f3..96ff689cf756b3 100644 --- a/src/python_testing/TC_TIMESYNC_2_2.py +++ b/src/python_testing/TC_TIMESYNC_2_2.py @@ -63,6 +63,7 @@ async def test_TC_TIMESYNC_2_2(self): "Granularity out of expected range") asserts.assert_not_equal(granularity_dut, time_cluster.Enums.GranularityEnum.kNoTimeGranularity) + self.print_step(4, "Read UTC time") th_utc = utc_time_in_matter_epoch() utc_dut = await self.read_ts_attribute_expect_success(endpoint=endpoint, attribute=attributes.UTCTime) asserts.assert_is_not(utc_dut, NullValue, "Received null value for UTCTime after set") @@ -72,6 +73,12 @@ async def test_TC_TIMESYNC_2_2(self): tolerance = timedelta(minutes=1) compare_time(received=utc_dut, utc=th_utc, tolerance=tolerance) + self.print_step(5, "Read time source") + if (self.check_pics("TIMESYNC.S.A0002")): + if utc_dut_initial is NullValue: + source = await self.read_ts_attribute_expect_success(endpoint=endpoint, attribute=attributes.TimeSource) + asserts.assert_equal(source, Clusters.Objects.TimeSynchronization.Enums.TimeSourceEnum.kAdmin) + if __name__ == "__main__": default_matter_test_main()