Skip to content

Commit

Permalink
Added updated Door lock scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
kowsisoundhar12 committed Aug 24, 2022
1 parent 3d6fdd8 commit d3175eb
Show file tree
Hide file tree
Showing 5 changed files with 106 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/app/tests/suites/certification/Test_TC_DRLK_2_1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1370,9 +1370,9 @@ tests:
verification: |
This is an Optional attribute, so its not compulsory to get the expected outcome
./chip-tool doorlock write 40 0 1 1
./chip-tool doorlock write-by-id 40 0 1 1
Verify "DUT responds with UNSUPPORTED_WRITE" on the TH(Chip-tool) Log:
Verify "DUT responds with UNSUPPORTED_ATTRIBUTE" on the TH(Chip-tool) Log:
[1653637444.331118][3599:3604] CHIP:DMG: StatusIB =
[1653637444.331165][3599:3604] CHIP:DMG: {
Expand Down
16 changes: 16 additions & 0 deletions src/app/tests/suites/certification/Test_TC_DRLK_2_10.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,22 @@ tests:
4. Open 2nd terminal of DUT and provide the below command to obtain PID of DUT
ps -aef|grep lock-app
5. Follow the Verification step below to generate the event in 2nd terminal of DUT
Pre-Conditions
"1 TH is commissioned with the DUT
2 Lock device is the DUT
Before sending the Events proceed following steps:
1. Send Set User Command and Get User for setting User.
2. Send Set Credential Command and Get Credential Status for setting PIN code.
After sending Events with all condition proceed following step
1. Send Clear Credential and Clear User Command."
disabled: true

- label:
Expand Down
7 changes: 7 additions & 0 deletions src/app/tests/suites/certification/Test_TC_DRLK_2_8.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,13 @@ config:
endpoint: 0

tests:
- label: "Pre-Conditions"
verification: |
1 TH is commissioned with the DUT
2 Lock device is the DUT
disabled: true

- label:
"TH reads NumberOfTotalUsers Supported attribute and saves for future
use."
Expand Down
5 changes: 3 additions & 2 deletions src/app/tests/suites/certification/Test_TC_DRLK_3_2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,12 @@ tests:
For DUT as client test cases, Chip-tool command used below are an example to verify the functionality. For certification test, we expect DUT should have a capability or way to run the equivalent command.
disabled: true

- label: "Note"
- label: "Pre-Conditions"
verification: |
1. TH is commissioned with the DUT
2.Steps 4- 12 need a User added to the lock
2.Steps 4- 12 need a User added to the
lock
disabled: true

- label: "DUT sends Lock Door command to TH."
Expand Down
78 changes: 78 additions & 0 deletions src/app/tests/suites/certification/Test_TC_DRLK_3_3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,21 @@ tests:
4. Open 2nd terminal of DUT and provide the below command to obtain PID of DUT
ps -aef|grep lock-app
5. Follow the Verification step below to generate the event in 2nd terminal of DUT "
"Pre-Conditions
Before sending the Events proceed following step:
1. Send Set User Command and Get User for setting User.
2. Send Set Credential Command and Get Credential Status for setting PIN code.
After sending Events with all condition proceed following step
1. Send Clear Credential and Clear User Command.
"
disabled: true

- label: "TH will initiate DoorLockAlarm Event (LockJammed scenario)"
Expand Down Expand Up @@ -446,3 +461,66 @@ tests:
[1658400921.175531][3227:3227] CHIP:DMG: AccessControl: allowed
[1658400921.175603][3227:3227] CHIP:DMG: Fetched 3 events
disabled: true

- label: ""
verification: |
./chip-tool doorlock clear-credential "{ "credentialType" : 1 , "credentialIndex" : 1 }" 1 1 --timedInteractionTimeoutMs 1000
Verify " DUT sends success response" on the TH(Lock-app) Log:
[1657115878.582559][8804:8804] CHIP:DMG: InvokeRequestMessage =
[1657115878.582642][8804:8804] CHIP:DMG: {
[1657115878.582698][8804:8804] CHIP:DMG: suppressResponse = false,
[1657115878.582787][8804:8804] CHIP:DMG: timedRequest = true,
[1657115878.582848][8804:8804] CHIP:DMG: InvokeRequests =
[1657115878.582948][8804:8804] CHIP:DMG: [
[1657115878.583009][8804:8804] CHIP:DMG: CommandDataIB =
[1657115878.583098][8804:8804] CHIP:DMG: {
[1657115878.583161][8804:8804] CHIP:DMG: CommandPathIB =
[1657115878.583265][8804:8804] CHIP:DMG: {
[1657115878.583366][8804:8804] CHIP:DMG: EndpointId = 0x1,
[1657115878.583607][8804:8804] CHIP:DMG: ClusterId = 0x101,
[1657115878.583724][8804:8804] CHIP:DMG: CommandId = 0x26,
[1657115878.583802][8804:8804] CHIP:DMG: },
[1657115878.583906][8804:8804] CHIP:DMG:
[1657115878.583972][8804:8804] CHIP:DMG: CommandFields =
[1657115878.584068][8804:8804] CHIP:DMG: {
[1657115878.584155][8804:8804] CHIP:DMG: 0x0 =
[1657115878.584234][8804:8804] CHIP:DMG: {
[1657115878.584335][8804:8804] CHIP:DMG: 0x0 = 1,
[1657115878.584442][8804:8804] CHIP:DMG: 0x1 = 1,
[1657115878.584527][8804:8804] CHIP:DMG: },
[1657115878.584624][8804:8804] CHIP:DMG: },
[1657115878.584695][8804:8804] CHIP:DMG: },
[1657115878.584795][8804:8804] CHIP:DMG:
[1657115878.584890][8804:8804] CHIP:DMG: ],
[1657115878.584994][8804:8804] CHIP:DMG:
[1657115878.585054][8804:8804] CHIP:DMG: InteractionModelRevision = 1
[1657115878.585131][8804:8804] CHIP:DMG: },
[1657115878.585305][8804:8804] CHIP:DMG: AccessControl: checking f=1 a=c s=0x000000000001B669 t= c=0x0000_0101 e=1 p=a
[1657115878.585416][8804:8804] CHIP:DMG: AccessControl: allowed
./chip-tool doorlock clear-user 1 1 1 --timedInteractionTimeoutMs 1000
Verify " DUT sends success response" on the TH(Lock-app) Log:
[1658399465.849095][2474:2474] CHIP:DMG: CommandPathIB =
[1658399465.849133][2474:2474] CHIP:DMG: {
[1658399465.849169][2474:2474] CHIP:DMG: EndpointId = 0x1,
[1658399465.849208][2474:2474] CHIP:DMG: ClusterId = 0x101,
[1658399465.849245][2474:2474] CHIP:DMG: CommandId = 0x1d,
[1658399465.849279][2474:2474] CHIP:DMG: },
[1658399465.849316][2474:2474] CHIP:DMG:
[1658399465.849348][2474:2474] CHIP:DMG: CommandFields =
[1658399465.849386][2474:2474] CHIP:DMG: {
[1658399465.849422][2474:2474] CHIP:DMG: 0x0 = 2,
[1658399465.849459][2474:2474] CHIP:DMG: },
[1658399465.849491][2474:2474] CHIP:DMG: },
[1658399465.849528][2474:2474] CHIP:DMG:
[1658399465.849555][2474:2474] CHIP:DMG: ],
[1658399465.849589][2474:2474] CHIP:DMG:
[1658399465.849616][2474:2474] CHIP:DMG: InteractionModelRevision = 1
[1658399465.849643][2474:2474] CHIP:DMG: },
[1658399465.849717][2474:2474] CHIP:DMG: AccessControl: checking f=1 a=c s=0x000000000001B669 t= c=0x0000_0101 e=1 p=a
[1658399465.849757][2474:2474] CHIP:DMG: AccessControl: allowed
disabled: true

0 comments on commit d3175eb

Please sign in to comment.