@@ -220,7 +220,7 @@ async def get_user(self, userindex, username, useruniqueid, credentiallist, expe
220
220
except InteractionModelError as e :
221
221
asserts .assert_equal (e .status , expected_status , f"Unexpected error returned: { e } " )
222
222
223
- async def get_credentials_status (self , credentialIndex : int , credentialType : drlkcluster .Enums .CredentialTypeEnum , credential_exists ):
223
+ async def get_credentials_status (self , credentialIndex : int , credentialType : drlkcluster .Enums .CredentialTypeEnum , credential_exists , next_credential_index ):
224
224
225
225
try :
226
226
credentials_struct = drlkcluster .Structs .CredentialStruct (credentialIndex = credentialIndex ,
@@ -237,14 +237,17 @@ async def get_credentials_status(self, credentialIndex: int, credentialType: drl
237
237
asserts .assert_true (response .userIndex == NullValue ,
238
238
"Error when executing GetCredentialStatus command, userIndex={}" .format (
239
239
str (response .userIndex )))
240
+ asserts .assert_true (response .nextCredentialIndex == next_credential_index ,
241
+ "Error when executing GetCredentialStatus command, nextCredentialIndex={}" .format (
242
+ str (response .nextCredentialIndex )))
240
243
return response
241
244
except InteractionModelError as e :
242
245
logging .error (e )
243
246
asserts .assert_equal (e .status , Status .Success , f"Unexpected error returned: { e } " )
244
247
245
248
async def set_credential_cmd (self , credential_enum : drlkcluster .Enums .CredentialTypeEnum , statuscode , credentialIndex ,
246
249
operationType , userIndex , credentialData , userStatus , userType ):
247
- custom_stautus_code = 149
250
+ custom_status_code = 149
248
251
249
252
credentials = drlkcluster .Structs .CredentialStruct (
250
253
credentialType = credential_enum ,
@@ -265,7 +268,7 @@ async def set_credential_cmd(self, credential_enum: drlkcluster.Enums.Credential
265
268
asserts .assert_true (type_matches (response , drlkcluster .Commands .SetCredentialResponse ),
266
269
"Unexpected return type for SetCredential" )
267
270
asserts .assert_equal (response .userIndex , NullValue )
268
- if (statuscode != custom_stautus_code ):
271
+ if (statuscode != custom_status_code ):
269
272
asserts .assert_true (response .status == statuscode ,
270
273
"Error sending SetCredential command, status={}" .format (str (response .status )))
271
274
else :
@@ -432,7 +435,7 @@ async def test_TC_DRLK_2_9(self):
432
435
if self .pics_guard (self .check_pics ("DRLK.S.F00" ) and self .check_pics ("DRLK.S.F08" )
433
436
and self .check_pics ("DRLK.S.C24.Rsp" ) and self .check_pics ("DRLK.S.C25.Tx" )):
434
437
await self .get_credentials_status (credentialIndex = credentialIndex_1 ,
435
- credentialType = drlkcluster .Enums .CredentialTypeEnum .kPin , credential_exists = True )
438
+ credentialType = drlkcluster .Enums .CredentialTypeEnum .kPin , credential_exists = True , next_credential_index = NullValue )
436
439
self .step ("4" )
437
440
if self .pics_guard (self .check_pics ("DRLK.S.F00" ) and self .check_pics ("DRLK.S.F08" )
438
441
and self .check_pics ("DRLK.S.C22.Rsp" ) and self .check_pics ("DRLK.S.C23.Tx" )):
@@ -479,7 +482,7 @@ async def test_TC_DRLK_2_9(self):
479
482
self .step ("9a" )
480
483
if self .pics_guard (self .check_pics ("DRLK.S.F00" ) and self .check_pics ("DRLK.S.F08" ) and self .check_pics ("DRLK.S.C24.Rsp" )):
481
484
await self .get_credentials_status (credentialIndex = credentialIndex_1 ,
482
- credentialType = drlkcluster .Enums .CredentialTypeEnum .kPin , credential_exists = False )
485
+ credentialType = drlkcluster .Enums .CredentialTypeEnum .kPin , credential_exists = False , next_credential_index = NullValue )
483
486
self .step ("9b" )
484
487
if self .pics_guard (self .check_pics ("DRLK.S.F08" ) and self .check_pics ("DRLK.S.C1d.Rsp" )):
485
488
await self .send_clear_user_cmd (user_index = 1 )
@@ -516,7 +519,7 @@ async def test_TC_DRLK_2_9(self):
516
519
self .step ("13" )
517
520
if self .pics_guard (self .check_pics ("DRLK.S.F00" ) and self .check_pics ("DRLK.S.F08" ) and self .check_pics ("DRLK.S.C24.Rsp" ) and self .check_pics ("DRLK.S.C25.Tx" )):
518
521
await self .get_credentials_status (credentialIndex = credentialIndex_1 ,
519
- credentialType = drlkcluster .Enums .CredentialTypeEnum .kPin , credential_exists = False )
522
+ credentialType = drlkcluster .Enums .CredentialTypeEnum .kPin , credential_exists = False , next_credential_index = NullValue )
520
523
self .step ("14a" )
521
524
if self .pics_guard (self .check_pics ("DRLK.S.F08" ) and self .check_pics ("DRLK.S.C26.Rsp" )):
522
525
feature_map = await self .read_attributes_from_dut (endpoint = self .app_cluster_endpoint ,
0 commit comments