Skip to content

Commit 9d88e83

Browse files
committed
Updated DRLK-2.5 test case as per PR comment
1.correted test step description for step 4,5,6 and 9 2.Corrected steps 5,6 and 9
1 parent 124f306 commit 9d88e83

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

src/python_testing/TC_DRLK_2_5.py

+12-10
Original file line numberDiff line numberDiff line change
@@ -53,17 +53,17 @@ def steps_TC_DRLK_2_5(self) -> list[TestStep]:
5353
TestStep("3", "TH sends GetWeekDaySchedule Command to DUT.",
5454
"Verify that the DUT sends GetWeekDayScheduleResponse command with expected values."),
5555
TestStep("4", "TH sends SetWeekDaySchedule Command to DUT.",
56-
"Verify that the DUT responds with SetCredentialResponse command with Status INVALID_COMMAND."),
56+
"Verify that the DUT responds with INVALID_COMMAND."),
5757
TestStep("5", "TH sends SetWeekDaySchedule Command to DUT.",
58-
"Verify that the DUT responds with SetCredentialResponse command with Status INVALID_COMMAND."),
58+
"Verify that the DUT responds with INVALID_COMMAND."),
5959
TestStep("6", "TH sends SetWeekDaySchedule Command to DUT.",
60-
"Verify that the DUT responds with SetCredentialResponse command with Status INVALID_COMMAND."),
60+
"Verify that the DUT responds with INVALID_COMMAND."),
6161
TestStep("7", "TH sends SetWeekDaySchedule Command to DUT.",
62-
"Verify that the DUT responds with SetCredentialResponse command with Status INVALID_COMMAND."),
62+
"Verify that the DUT responds with INVALID_COMMAND."),
6363
TestStep("8", "TH sends GetWeekDaySchedule Command to DUT.",
64-
"Verify that the DUT responds with SetCredentialResponse command with Status INVALID_COMMAND."),
64+
"Verify that the DUT responds with with INVALID_COMMAND."),
6565
TestStep("9", "TH sends GetWeekDaySchedule Command to DUT.",
66-
"Verify that the DUT responds with SetCredentialResponse command with Status NOT_FOUND."),
66+
"Verify that the DUT responds with GetWeekDayScheduleResponse command with Status NOT_FOUND."),
6767
TestStep("10a", "TH sends ClearWeekDaySchedule Command to DUT.", "Verify that the DUT sends SUCCESS response."),
6868
TestStep("10b", "TH sends ClearWeekDaySchedule Command to DUT.", "Verify that the DUT sends INVALID_COMMAND response."),
6969
TestStep("10c", "TH sends ClearWeekDaySchedule Command to DUT.", "Verify that the DUT sends INVALID_COMMAND response."),
@@ -192,6 +192,8 @@ async def test_TC_DRLK_2_5(self):
192192
cluster=drlkcluster,
193193
attribute=Clusters.DoorLock.Attributes.NumberOfWeekDaySchedulesSupportedPerUser)
194194
logging.info("NumberOfWeekDaySchedulesSupportedPerUser %s" % (number_week_day_schedules_supported_per_user))
195+
asserts.assert_in(number_week_day_schedules_supported_per_user, range(
196+
0, 255), "NumberOfWeekDaySchedulesSupportedPerUser value is out of range")
195197
self.step("2a")
196198
if self.pics_guard(self.check_pics("DRLK.S.F08") and self.check_pics("DRLK.S.C1a.Rsp")):
197199
try:
@@ -267,8 +269,8 @@ async def test_TC_DRLK_2_5(self):
267269
Status.InvalidCommand)
268270
self.step("5")
269271
if self.pics_guard(self.check_pics("DRLK.S.F04") and self.check_pics("DRLK.S.C0b.Rsp")):
270-
week_day_index = 0 # invalid value
271-
day_mask_map_index = 2 # valid value
272+
week_day_index = 1 # Valid value
273+
day_mask_map_index = 0 # invalid value
272274
await self.set_week_days_schedule_cmd(
273275
week_day_index,
274276
user_index,
@@ -281,7 +283,7 @@ async def test_TC_DRLK_2_5(self):
281283
self.step("6")
282284
if self.pics_guard(self.check_pics("DRLK.S.F04") and self.check_pics("DRLK.S.C0b.Rsp")):
283285
week_day_index = 1 # valid value
284-
day_mask_map_index = 0 # invalid value
286+
day_mask_map_index = 128 # invalid value
285287
await self.set_week_days_schedule_cmd(
286288
week_day_index,
287289
user_index,
@@ -332,7 +334,7 @@ async def test_TC_DRLK_2_5(self):
332334
start_Minute,
333335
end_Hour,
334336
end_Minute,
335-
Status.InvalidCommand)
337+
Status.NotFound)
336338
self.step("10a")
337339
if self.pics_guard(self.check_pics("DRLK.S.F04") and self.check_pics("DRLK.S.C0d.Rsp")):
338340
week_day_index = 1

0 commit comments

Comments
 (0)