Skip to content

Commit

Permalink
Updated PCC test cases to use new feature PICS
Browse files Browse the repository at this point in the history
  • Loading branch information
ReneJosefsen committed Jan 18, 2023
1 parent 054d7bf commit 59a8ede
Show file tree
Hide file tree
Showing 7 changed files with 619 additions and 208 deletions.
39 changes: 21 additions & 18 deletions src/app/tests/suites/certification/PICS.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2807,6 +2807,27 @@ PICS:
id: FLW.M.FlowChange

# Pump Configuration and Control cluster
- label: "Supports operating in constant pressure mode"
id: PCC.S.F00

- label: "Supports operating in compensated pressure mode"
id: PCC.S.F01

- label: "Supports operating in constant flow mode"
id: PCC.S.F02

- label: "Supports operating in constant speed mode"
id: PCC.S.F03

- label: "Supports operating in constant temperature mode"
id: PCC.S.F04

- label: "Supports operating in automatic mode"
id: PCC.S.F05

- label: "Supports operating using local settings"
id: PCC.S.F06

- label: "Does the device implement the MaxPressure attribute?"
id: PCC.S.A0000

Expand Down Expand Up @@ -2876,24 +2897,6 @@ PICS:
- label: "Does the device implement the LifetimeEnergyConsumed attribute?"
id: PCC.S.A0021

- label: "Does the device implement the ConstantSpeed control mode?"
id: PCC.M.ControlModeConstSpeed

- label: "Does the device implement the ConstantPressure control mode?"
id: PCC.M.ControlModeConstPressure

- label: "Does the device implement the ProportionalPressure control mode?"
id: PCC.M.ControlModeCompPressure

- label: "Does the device implement the ConstantFlow control mode?"
id: PCC.M.ControlModeConstFlow

- label: "Does the device implement the ConstantTemperature control mode?"
id: PCC.M.ControlModeConstTemp

- label: "Does the device implement the Automatic control mode?"
id: PCC.M.ControlModeAuto

#Power Source Cluster
- label: "Does the device implement the Status attribute?"
id: PS.S.A0000
Expand Down
68 changes: 67 additions & 1 deletion src/app/tests/suites/certification/Test_TC_PCC_1_1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,17 +35,83 @@ tests:
command: "readAttribute"
attribute: "ClusterRevision"
response:
value: 3
value: 4
constraints:
type: int16u

- label: "TH reads the FeatureMap attribute from the DUT"
PICS:
" !PCC.S.F00 && !PCC.S.F01 && !PCC.S.F02 && !PCC.S.F03 &&
!PCC.S.F04 && !PCC.S.F06 && !PCC.S.F06 "
command: "readAttribute"
attribute: "FeatureMap"
response:
value: 0
constraints:
type: bitmap32

- label: "Given PCC.S.F00(PRSCONST) ensure featuremap has the correct bit set"
PICS: PCC.S.F00
command: "readAttribute"
attribute: "FeatureMap"
response:
constraints:
type: bitmap32
hasMasksSet: [0x1]

- label: "Given PCC.S.F01(PRSCOMP) ensure featuremap has the correct bit set"
PICS: PCC.S.F01
command: "readAttribute"
attribute: "FeatureMap"
response:
constraints:
type: bitmap32
hasMasksSet: [0x2]

- label: "Given PCC.S.F02(FLW) ensure featuremap has the correct bit set"
PICS: PCC.S.F02
command: "readAttribute"
attribute: "FeatureMap"
response:
constraints:
type: bitmap32
hasMasksSet: [0x4]

- label: "Given PCC.S.F03(SPD) ensure featuremap has the correct bit set"
PICS: PCC.S.F03
command: "readAttribute"
attribute: "FeatureMap"
response:
constraints:
type: bitmap32
hasMasksSet: [0x8]

- label: "Given PCC.S.F04(TEMP) ensure featuremap has the correct bit set"
PICS: PCC.S.F04
command: "readAttribute"
attribute: "FeatureMap"
response:
constraints:
type: bitmap32
hasMasksSet: [0x10]

- label: "Given PCC.S.F05(AUTO) ensure featuremap has the correct bit set"
PICS: PCC.S.F05
command: "readAttribute"
attribute: "FeatureMap"
response:
constraints:
type: bitmap32
hasMasksSet: [0x20]

- label: "Given PCC.S.F06(LOCAL) ensure featuremap has the correct bit set"
PICS: PCC.S.F06
command: "readAttribute"
attribute: "FeatureMap"
response:
constraints:
type: bitmap32
hasMasksSet: [0x40]

- label: "TH reads the AttributeList attribute from the DUT"
command: "readAttribute"
Expand Down
8 changes: 4 additions & 4 deletions src/app/tests/suites/certification/Test_TC_PCC_2_2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,14 +48,14 @@ tests:
- label: "TH write 1 (Minimum) to the OperationMode attribute to DUT"
command: "writeAttribute"
attribute: "OperationMode"
PICS: PCC.S.A0020 && PCC.M.ControlModeConstSpeed
PICS: PCC.S.F03 && PCC.S.A0020
arguments:
value: 1

- label: "TH reads from the DUT the EffectiveOperationMode attribute"
command: "readAttribute"
attribute: "EffectiveOperationMode"
PICS: PCC.S.A0011 && PCC.M.ControlModeConstSpeed
PICS: PCC.S.F03 && PCC.S.A0011
response:
value: 1

Expand All @@ -64,14 +64,14 @@ tests:
time."
command: "writeAttribute"
attribute: "OperationMode"
PICS: PCC.S.A0020 && PCC.M.ControlModeConstSpeed
PICS: PCC.S.F03 && PCC.S.A0020
arguments:
value: 2

- label: "TH reads from the DUT the EffectiveOperationMode attribute"
command: "readAttribute"
attribute: "EffectiveOperationMode"
PICS: PCC.S.A0011 && PCC.M.ControlModeConstSpeed
PICS: PCC.S.F03 && PCC.S.A0011
response:
value: 2

Expand Down
24 changes: 12 additions & 12 deletions src/app/tests/suites/certification/Test_TC_PCC_2_3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,83 +48,83 @@ tests:
- label: "Write 0 to the ControlMode attribute to DUT"
command: "writeAttribute"
attribute: "ControlMode"
PICS: PCC.S.A0021 && PCC.M.ControlModeConstSpeed
PICS: PCC.S.F03 && PCC.S.A0021
arguments:
value: 0

- label: "Reads the attribute: EffectiveControlMode"
command: "readAttribute"
attribute: "EffectiveControlMode"
PICS: PCC.S.A0012 && PCC.M.ControlModeConstSpeed
PICS: PCC.S.F03 && PCC.S.A0012
response:
value: 0

- label: "Write 1 to the ControlMode attribute to DUT"
command: "writeAttribute"
attribute: "ControlMode"
PICS: PCC.S.A0021 && PCC.M.ControlModeConstPressure
PICS: PCC.S.F00 && PCC.S.A0021
arguments:
value: 1

- label: "Reads the attribute: EffectiveControlMode"
command: "readAttribute"
attribute: "EffectiveControlMode"
PICS: PCC.S.A0012 && PCC.M.ControlModeConstPressure
PICS: PCC.S.F00 && PCC.S.A0012
response:
value: 1

- label: "Write 2 to the ControlMode attribute to DUT"
command: "writeAttribute"
attribute: "ControlMode"
PICS: PCC.S.A0021 && PCC.M.ControlModeCompPressure
PICS: PCC.S.F01 && PCC.S.A0021
arguments:
value: 2

- label: "Reads the attribute: EffectiveControlMode"
command: "readAttribute"
attribute: "EffectiveControlMode"
PICS: PCC.S.A0012 && PCC.M.ControlModeCompPressure
PICS: PCC.S.F01 && PCC.S.A0012
response:
value: 2

- label: "Write 3 to the ControlMode attribute to DUT"
command: "writeAttribute"
attribute: "ControlMode"
PICS: PCC.S.A0021 && PCC.M.ControlModeConstFlow
PICS: PCC.S.F02 && PCC.S.A0021
arguments:
value: 3

- label: "Reads the attribute: EffectiveControlMode"
command: "readAttribute"
attribute: "EffectiveControlMode"
PICS: PCC.S.A0012 && PCC.M.ControlModeConstFlow
PICS: PCC.S.F02 && PCC.S.A0012
response:
value: 3

- label: "Write 5 to the ControlMode attribute to DUT"
command: "writeAttribute"
attribute: "ControlMode"
PICS: PCC.S.A0021 && PCC.M.ControlModeConstTemp
PICS: PCC.S.F04 && PCC.S.A0021
arguments:
value: 5

- label: "Reads the attribute: EffectiveControlMode"
command: "readAttribute"
attribute: "EffectiveControlMode"
PICS: PCC.S.A0012 && PCC.M.ControlModeConstTemp
PICS: PCC.S.F04 && PCC.S.A0012
response:
value: 5

- label: "Write 7 to the ControlMode attribute to DUT"
command: "writeAttribute"
attribute: "ControlMode"
PICS: PCC.S.A0021 && PCC.M.ControlModeAuto
PICS: PCC.S.F05 && PCC.S.A0021
arguments:
value: 7

- label: "Reads the attribute: EffectiveControlMode"
command: "readAttribute"
attribute: "EffectiveControlMode"
PICS: PCC.S.A0012 && PCC.M.ControlModeAuto
PICS: PCC.S.F02 && PCC.S.A0012
response:
value: 7
13 changes: 7 additions & 6 deletions src/app/tests/suites/certification/ci-pics-values
Original file line number Diff line number Diff line change
Expand Up @@ -730,6 +730,13 @@ FLW.S.A0003=1
FLW.M.FlowChange=1

#Pump Configuration and Control
PCC.S.F00=1
PCC.S.F01=0
PCC.S.F02=0
PCC.S.F03=0
PCC.S.F04=0
PCC.S.F05=0
PCC.S.F06=0
PCC.S.A0000=1
PCC.S.A0001=1
PCC.S.A0002=1
Expand All @@ -753,12 +760,6 @@ PCC.S.A0016=1
PCC.S.A0017=1
PCC.S.A0020=1
PCC.S.A0021=1
PCC.M.ControlModeConstSpeed=1
PCC.M.ControlModeConstPressure=1
PCC.M.ControlModeCompPressure=1
PCC.M.ControlModeConstFlow=1
PCC.M.ControlModeConstTemp=1
PCC.M.ControlModeAuto=1

#Power Source Cluster
PS.S.A0000=1
Expand Down
Loading

0 comments on commit 59a8ede

Please sign in to comment.