Skip to content

Commit

Permalink
Update smokeco tests as per test plan document update (#28843)
Browse files Browse the repository at this point in the history
* Add SMOKECO tests serial number

* Fix the difference between scripts and test plan

* Keep priorities and examples consistent

* Reduce WaitForMs time

* Modify minInterval and maxInterval

* Remove keepSubscriptions

* Add subscribe after WaitForMs

* Disable TC-SMOKECO-2.6 in darwin and regen zap

---------

Co-authored-by: Hare <renilr0@outlook.com>
  • Loading branch information
2 people authored and pull[bot] committed Nov 23, 2023
1 parent f6bd244 commit 7af99f6
Show file tree
Hide file tree
Showing 9 changed files with 661 additions and 2,150 deletions.
2 changes: 2 additions & 0 deletions examples/darwin-framework-tool/templates/tests/ciTests.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@
"Test_TC_SMOKECO_2_3",
"Test_TC_SMOKECO_2_4",
"Test_TC_SMOKECO_2_5",
"Disabled due to undefined properties",
"Test_TC_SMOKECO_2_6",
"Disabled because the power source configuration cluster is now deprecated and not present in all-clusters",
"Test_TC_PSCFG_1_1",
"Test_TC_PSCFG_2_1",
Expand Down
71 changes: 42 additions & 29 deletions src/app/tests/suites/certification/Test_TC_SMOKECO_1_1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,23 @@ config:
endpoint: 1

tests:
- label: "Commission DUT to TH"
- label: "Step 1: Commission DUT to TH"
cluster: "DelayCommands"
command: "WaitForCommissionee"
arguments:
values:
- name: "nodeId"
value: nodeId

- label: "TH reads the ClusterRevision attribute from the DUT"
- label: "Step 2: TH reads the ClusterRevision attribute from the DUT"
command: "readAttribute"
attribute: "ClusterRevision"
response:
value: 1
constraints:
type: int16u

- label: "TH reads from the DUT the FeatureMap attribute"
- label: "Step 3a: TH reads from the DUT the FeatureMap attribute"
PICS: "!SMOKECO.S.F00 && !SMOKECO.S.F01"
command: "readAttribute"
attribute: "FeatureMap"
Expand All @@ -48,7 +48,8 @@ tests:
constraints:
type: bitmap32

- label: "TH reads from the DUT the FeatureMap attribute(Smoke Alarm)"
- label:
"Step 3b: TH reads from the DUT the FeatureMap attribute(Smoke Alarm)"
PICS: SMOKECO.S.F00 && !SMOKECO.S.F01
command: "readAttribute"
attribute: "FeatureMap"
Expand All @@ -57,7 +58,7 @@ tests:
constraints:
type: bitmap32

- label: "TH reads from the DUT the FeatureMap attribute(CO Alarm)"
- label: "Step 3c: TH reads from the DUT the FeatureMap attribute(CO Alarm)"
PICS: SMOKECO.S.F01 && !SMOKECO.S.F00
command: "readAttribute"
attribute: "FeatureMap"
Expand All @@ -67,8 +68,8 @@ tests:
type: bitmap32

- label:
"TH reads from the DUT the FeatureMap attribute(Smoke Alarm & CO
Alarm)"
"Step 3d: TH reads from the DUT the FeatureMap attribute(Smoke Alarm &
CO Alarm)"
PICS: SMOKECO.S.F00 && SMOKECO.S.F01
command: "readAttribute"
attribute: "FeatureMap"
Expand All @@ -77,33 +78,38 @@ tests:
constraints:
type: bitmap32

- label: "TH reads from the DUT the AttributeList attribute"
- label: "Step 4a: TH reads from the DUT the AttributeList attribute"
command: "readAttribute"
attribute: "AttributeList"
response:
constraints:
type: list
contains: [0, 3, 5, 6, 7]
contains: [0, 3, 5, 6, 7, 65528, 65529, 65531, 65532, 65533]

- label: "TH reads from the DUT the AttributeList attribute(SmokeState)"
PICS: SMOKECO.S.A0001
- label:
"Step 4b: TH reads from the DUT the AttributeList
attribute(SmokeState)"
PICS: SMOKECO.S.A0001 && SMOKECO.S.F00
command: "readAttribute"
attribute: "AttributeList"
response:
constraints:
type: list
contains: [1]

- label: "TH reads from the DUT the AttributeList attribute(COState)"
PICS: SMOKECO.S.A0002
- label:
"Step 4c: TH reads from the DUT the AttributeList attribute(COState)"
PICS: SMOKECO.S.A0002 && SMOKECO.S.F01
command: "readAttribute"
attribute: "AttributeList"
response:
constraints:
type: list
contains: [2]

- label: "TH reads from the DUT the AttributeList attribute(DeviceMuted)"
- label:
"Step 4d: TH reads from the DUT the AttributeList
attribute(DeviceMuted)"
PICS: SMOKECO.S.A0004
command: "readAttribute"
attribute: "AttributeList"
Expand All @@ -113,7 +119,7 @@ tests:
contains: [4]

- label:
"TH reads from the DUT the AttributeList
"Step 4e: TH reads from the DUT the AttributeList
attribute(InterconnectSmokeAlarm)"
PICS: SMOKECO.S.A0008
command: "readAttribute"
Expand All @@ -124,7 +130,7 @@ tests:
contains: [8]

- label:
"TH reads from the DUT the AttributeList
"Step 4f: TH reads from the DUT the AttributeList
attribute(InterconnectCOAlarm)"
PICS: SMOKECO.S.A0009
command: "readAttribute"
Expand All @@ -135,7 +141,8 @@ tests:
contains: [9]

- label:
"TH reads from the DUT the AttributeList attribute(ContaminationState)"
"Step 4g: TH reads from the DUT the AttributeList
attribute(ContaminationState)"
PICS: SMOKECO.S.A000a
command: "readAttribute"
attribute: "AttributeList"
Expand All @@ -145,7 +152,7 @@ tests:
contains: [10]

- label:
"TH reads from the DUT the AttributeList
"Step 4h: TH reads from the DUT the AttributeList
attribute(SmokeSensitivityLevel)"
PICS: SMOKECO.S.A000b
command: "readAttribute"
Expand All @@ -155,7 +162,9 @@ tests:
type: list
contains: [11]

- label: "TH reads from the DUT the AttributeList attribute(ExpiryDate)"
- label:
"Step 4i: TH reads from the DUT the AttributeList
attribute(ExpiryDate)"
PICS: SMOKECO.S.A000c
command: "readAttribute"
attribute: "AttributeList"
Expand All @@ -164,7 +173,7 @@ tests:
type: list
contains: [12]

- label: "TH reads from the DUT the EventList attribute"
- label: "Step 5a: TH reads from the DUT the EventList attribute"
PICS: PICS_EVENT_LIST_ENABLED
command: "readAttribute"
attribute: "EventList"
Expand All @@ -173,7 +182,8 @@ tests:
type: list
contains: [2, 3, 4, 5, 10]

- label: "TH reads from the DUT the EventList attribute(SmokeAlarm)"
- label:
"Step 5b: TH reads from the DUT the EventList attribute(SmokeAlarm)"
PICS: PICS_EVENT_LIST_ENABLED && SMOKECO.S.E00
command: "readAttribute"
attribute: "EventList"
Expand All @@ -182,7 +192,7 @@ tests:
type: list
contains: [0]

- label: "TH reads from the DUT the EventList attribute(COAlarm)"
- label: "Step 5c: TH reads from the DUT the EventList attribute(COAlarm)"
PICS: PICS_EVENT_LIST_ENABLED && SMOKECO.S.E01
command: "readAttribute"
attribute: "EventList"
Expand All @@ -191,7 +201,8 @@ tests:
type: list
contains: [1]

- label: "TH reads from the DUT the EventList attribute(AlarmMuted)"
- label:
"Step 5d: TH reads from the DUT the EventList attribute(AlarmMuted)"
PICS: PICS_EVENT_LIST_ENABLED && SMOKECO.S.E06
command: "readAttribute"
attribute: "EventList"
Expand All @@ -200,7 +211,7 @@ tests:
type: list
contains: [6]

- label: "TH reads from the DUT the EventList attribute(MuteEnded)"
- label: "Step 5e: TH reads from the DUT the EventList attribute(MuteEnded)"
PICS: PICS_EVENT_LIST_ENABLED && SMOKECO.S.E07
command: "readAttribute"
attribute: "EventList"
Expand All @@ -210,7 +221,8 @@ tests:
contains: [7]

- label:
"TH reads from the DUT the EventList attribute(InterconnectSmokeAlarm)"
"Step 5f: TH reads from the DUT the EventList
attribute(InterconnectSmokeAlarm)"
PICS: PICS_EVENT_LIST_ENABLED && SMOKECO.S.E08
command: "readAttribute"
attribute: "EventList"
Expand All @@ -220,7 +232,8 @@ tests:
contains: [8]

- label:
"TH reads from the DUT the EventList attribute(InterconnectCOAlarm)"
"Step 5g: TH reads from the DUT the EventList
attribute(InterconnectCOAlarm)"
PICS: PICS_EVENT_LIST_ENABLED && SMOKECO.S.E09
command: "readAttribute"
attribute: "EventList"
Expand All @@ -229,7 +242,7 @@ tests:
type: list
contains: [9]

- label: "TH reads from the DUT the AcceptedCommandList attribute"
- label: "Step 6a: TH reads from the DUT the AcceptedCommandList attribute"
PICS: "!SMOKECO.S.C00.Rsp"
command: "readAttribute"
attribute: "AcceptedCommandList"
Expand All @@ -238,7 +251,7 @@ tests:
constraints:
type: list

- label: "TH reads from the DUT the AcceptedCommandList attribute"
- label: "Step 6b: TH reads from the DUT the AcceptedCommandList attribute"
PICS: SMOKECO.S.C00.Rsp
command: "readAttribute"
attribute: "AcceptedCommandList"
Expand All @@ -247,7 +260,7 @@ tests:
type: list
contains: [0]

- label: "TH reads from the DUT the GeneratedCommandList attribute"
- label: "Step 7: TH reads from the DUT the GeneratedCommandList attribute"
command: "readAttribute"
attribute: "GeneratedCommandList"
response:
Expand Down
30 changes: 16 additions & 14 deletions src/app/tests/suites/certification/Test_TC_SMOKECO_2_1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ config:
endpoint: 1

tests:
- label: "Commission DUT to TH"
- label: "Step 1: Commission DUT to TH"
cluster: "DelayCommands"
command: "WaitForCommissionee"
arguments:
values:
- name: "nodeId"
value: nodeId

- label: "TH reads from the DUT the ExpressedState attribute"
- label: "Step 2: TH reads from the DUT the ExpressedState attribute"
PICS: SMOKECO.S.A0000
command: "readAttribute"
attribute: "ExpressedState"
Expand All @@ -41,7 +41,7 @@ tests:
minValue: 0
maxValue: 8

- label: "TH reads from the DUT the SmokeState attribute"
- label: "Step 3: TH reads from the DUT the SmokeState attribute"
PICS: SMOKECO.S.A0001
command: "readAttribute"
attribute: "SmokeState"
Expand All @@ -51,7 +51,7 @@ tests:
minValue: 0
maxValue: 2

- label: "TH reads from the DUT the COState attribute"
- label: "Step 4: TH reads from the DUT the COState attribute"
PICS: SMOKECO.S.A0002
command: "readAttribute"
attribute: "COState"
Expand All @@ -61,7 +61,7 @@ tests:
minValue: 0
maxValue: 2

- label: "TH reads from the DUT the BatteryAlert attribute"
- label: "Step 5: TH reads from the DUT the BatteryAlert attribute"
PICS: SMOKECO.S.A0003
command: "readAttribute"
attribute: "BatteryAlert"
Expand All @@ -71,7 +71,7 @@ tests:
minValue: 0
maxValue: 2

- label: "TH reads from the DUT the DeviceMuted attribute"
- label: "Step 6: TH reads from the DUT the DeviceMuted attribute"
PICS: SMOKECO.S.A0004
command: "readAttribute"
attribute: "DeviceMuted"
Expand All @@ -81,23 +81,23 @@ tests:
minValue: 0
maxValue: 1

- label: "TH reads from the DUT the TestInProgress attribute"
- label: "Step 7: TH reads from the DUT the TestInProgress attribute"
PICS: SMOKECO.S.A0005
command: "readAttribute"
attribute: "TestInProgress"
response:
constraints:
type: boolean

- label: "TH reads from the DUT the HardwareFaultAlert attribute"
- label: "Step 8: TH reads from the DUT the HardwareFaultAlert attribute"
PICS: SMOKECO.S.A0006
command: "readAttribute"
attribute: "HardwareFaultAlert"
response:
constraints:
type: boolean

- label: "TH reads from the DUT the EndOfServiceAlert attribute"
- label: "Step 9: TH reads from the DUT the EndOfServiceAlert attribute"
PICS: SMOKECO.S.A0007
command: "readAttribute"
attribute: "EndOfServiceAlert"
Expand All @@ -107,7 +107,8 @@ tests:
minValue: 0
maxValue: 1

- label: "TH reads from the DUT the InterconnectSmokeAlarm attribute"
- label:
"Step 10: TH reads from the DUT the InterconnectSmokeAlarm attribute"
PICS: SMOKECO.S.A0008
command: "readAttribute"
attribute: "InterconnectSmokeAlarm"
Expand All @@ -117,7 +118,7 @@ tests:
minValue: 0
maxValue: 2

- label: "TH reads from the DUT the InterconnectCOAlarm attribute"
- label: "Step 11: TH reads from the DUT the InterconnectCOAlarm attribute"
PICS: SMOKECO.S.A0009
command: "readAttribute"
attribute: "InterconnectCOAlarm"
Expand All @@ -127,7 +128,7 @@ tests:
minValue: 0
maxValue: 2

- label: "TH reads from the DUT the ContaminationState attribute"
- label: "Step 12: TH reads from the DUT the ContaminationState attribute"
PICS: SMOKECO.S.A000a
command: "readAttribute"
attribute: "ContaminationState"
Expand All @@ -137,7 +138,8 @@ tests:
minValue: 0
maxValue: 3

- label: "TH reads from the DUT the SmokeSensitivityLevel attribute"
- label:
"Step 13: TH reads from the DUT the SmokeSensitivityLevel attribute"
PICS: SMOKECO.S.A000b
command: "readAttribute"
attribute: "SmokeSensitivityLevel"
Expand All @@ -147,7 +149,7 @@ tests:
minValue: 0
maxValue: 2

- label: "TH reads from the DUT the ExpiryDate attribute"
- label: "Step 14: TH reads from the DUT the ExpiryDate attribute"
PICS: SMOKECO.S.A000c
command: "readAttribute"
attribute: "ExpiryDate"
Expand Down
Loading

0 comments on commit 7af99f6

Please sign in to comment.