Skip to content

Commit

Permalink
Adding YAML Test Cases - Nov 2nd (#11364)
Browse files Browse the repository at this point in the history
* Adding Test Cases
1.Test_TC_BI_2_1
2.Test_TC_CC_9_2
3.Test_TC_CC_9_3
4.Test_TC_OCC_2_2
5.Test_TC_LVL_4_1
6.Test_TC_LVL_5_1
7.Test_TC_PRS_1_1
8.Test_TC_PRS_2_1
9.Test_TC_RH_2_2
10.Test_TC_TM_2_2
11.Test_TC_TSUIC_2_2
12.Test_TC_WNCV_2_5
13.Test_TC_DIAGSW_1_1

* Updating generated test script artifacts.

* Disabling Failing Test Step
  • Loading branch information
kvikrambhat authored and pull[bot] committed Dec 11, 2021
1 parent c5fa940 commit 1069066
Show file tree
Hide file tree
Showing 17 changed files with 11,172 additions and 3,934 deletions.
21 changes: 21 additions & 0 deletions examples/chip-tool/templates/tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ function getTests()
{
const BinaryInput = [
'Test_TC_BI_1_1',
'Test_TC_BI_2_1',
];

const ColorControl = [
Expand All @@ -42,6 +43,8 @@ function getTests()
'Test_TC_CC_7_3',
'Test_TC_CC_7_4',
'Test_TC_CC_8_1',
'Test_TC_CC_9_2',
'Test_TC_CC_9_3',
];

const DeviceManagement = [
Expand All @@ -62,12 +65,15 @@ function getTests()
const OccupancySensing = [
'Test_TC_OCC_1_1',
'Test_TC_OCC_2_1',
'Test_TC_OCC_2_2',
];

const LevelControl = [
'Test_TC_LVL_1_1',
'Test_TC_LVL_2_1',
'Test_TC_LVL_3_1',
'Test_TC_LVL_4_1',
'Test_TC_LVL_5_1',
];

const MediaControl = [
Expand All @@ -92,6 +98,11 @@ function getTests()
'Test_TC_OO_2_2',
];

const PressureMeasurement = [
'Test_TC_PRS_1_1',
'Test_TC_PRS_2_1',
];

const PumpConfigurationControl = [
'Test_TC_PCC_1_1',
'Test_TC_PCC_2_1',
Expand All @@ -102,11 +113,13 @@ function getTests()
const RelativeHumidityMeasurement = [
'Test_TC_RH_1_1',
'Test_TC_RH_2_1',
'Test_TC_RH_2_2',
];

const TemperatureMeasurement = [
'Test_TC_TM_1_1',
'Test_TC_TM_2_1',
'Test_TC_TM_2_2',
];

const Thermostat = [
Expand All @@ -116,6 +129,7 @@ function getTests()
const ThermostatUserConfiguration = [
'Test_TC_TSUIC_1_1',
'Test_TC_TSUIC_2_1',
'Test_TC_TSUIC_2_2',
];

const ThreadNetworkDiagnostics = [
Expand All @@ -125,6 +139,7 @@ function getTests()
const WindowCovering = [
'Test_TC_WNCV_1_1',
'Test_TC_WNCV_2_1',
'Test_TC_WNCV_2_5',
'Test_TC_WNCV_3_1',
'Test_TC_WNCV_3_2',
'Test_TC_WNCV_3_3',
Expand Down Expand Up @@ -157,6 +172,10 @@ function getTests()
'TestModeSelectCluster',
];

const SoftwareDiagnostics = [
'Test_TC_DIAGSW_1_1',
];

const Subscriptions = [
'TestSubscribe_OnOff',
];
Expand All @@ -171,6 +190,7 @@ function getTests()
MediaControl, //
OccupancySensing, //
OnOff, //
PressureMeasurement, //
PumpConfigurationControl, //
RelativeHumidityMeasurement, //
TemperatureMeasurement, //
Expand All @@ -180,6 +200,7 @@ function getTests()
WindowCovering, //
TV, //
Others, //
SoftwareDiagnostics, //
Subscriptions, //
];
return tests.flat(1);
Expand Down
283 changes: 283 additions & 0 deletions src/app/tests/suites/certification/Test_TC_BI_2_1.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,283 @@
# Copyright (c) 2021 Project CHIP Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

name: 18.2.1. [TC-BI-2.1] Attributes with server as DUT

config:
cluster: "Binary Input (Basic)"
endpoint: 1

tests:
- label: "Read mandatory non-global attribute: OutOfService"
command: "readAttribute"
attribute: "out of service"
response:
value: 0

- label: "Read mandatory non-global attribute constraints: OutOfService"
command: "readAttribute"
attribute: "out of service"
response:
constraints:
type: bool

- label:
"Write the default values to mandatory non-global attribute:
OutOfService"
command: "writeAttribute"
attribute: "out of service"
arguments:
value: 0

- label: "Reads back the mandatory non-global attribute: OutOfService"
command: "readAttribute"
attribute: "out of service"
response:
value: 0

- label: "Read mandatory non-global attribute constraints: PresentValue"
command: "readAttribute"
attribute: "present value"
response:
constraints:
type: bool

- label:
"Write the default values to mandatory non-global attribute:
PresentValue"
command: "writeAttribute"
attribute: "present value"
arguments:
value: 0

- label: "Reads back the mandatory non-global attribute: PresentValue"
command: "readAttribute"
attribute: "present value"
response:
value: 0

- label: "Read mandatory non-global attribute: StatusFlags"
command: "readAttribute"
attribute: "status flags"
response:
value: 0

- label: "Read mandatory non-global attribute constraints: StatusFlags"
command: "readAttribute"
attribute: "status flags"
response:
constraints:
type: map8
minValue: 0
maxValue: 15

- label:
"Write the default values to mandatory non-global attribute:
StatusFlags"
command: "writeAttribute"
attribute: "status flags"
arguments:
value: 0
response:
error: 1

- label: "Reads back the mandatory non-global attribute: StatusFlags"
command: "readAttribute"
attribute: "status flags"
response:
value: 0

#Issue #11142 Disabled all optional attribute checks
- label: "Read optional non-global attribute: ActiveText"
disabled: true
command: "readAttribute"
attribute: "active text"
response:
value: null

- label: "Read optional non-global attribute constraints: ActiveText"
disabled: true
command: "readAttribute"
attribute: "active text"
response:
constraints:
type: string

- label:
"Write the default values to optional non-global attribute: ActiveText"
disabled: true
command: "writeAttribute"
attribute: "active text"
arguments:
value: null

- label: "Reads back the optional non-global attribute: ActiveText"
disabled: true
command: "readAttribute"
attribute: "active text"
response:
value: null

- label: "Read optional non-global attribute: Description"
disabled: true
command: "readAttribute"
attribute: "description"
response:
value: null

- label: "Read optional non-global attribute constraints: Description"
disabled: true
command: "readAttribute"
attribute: "description"
response:
constraints:
type: string

- label:
"Write the default values to optional non-global attribute:
Description"
disabled: true
command: "writeAttribute"
attribute: "description"
arguments:
value: null

- label: "Reads back the optional non-global attribute: Description"
disabled: true
command: "readAttribute"
attribute: "description"
response:
value: null

- label: "Read optional non-global attribute: InactiveText"
disabled: true
command: "readAttribute"
attribute: "inactive text"
response:
value: null

- label: "Read optional non-global attribute constraints: InactiveText"
disabled: true
command: "readAttribute"
attribute: "inactive text"
response:
constraints:
type: string

- label:
"Write the default values to optional non-global attribute:
InactiveText"
disabled: true
command: "writeAttribute"
attribute: "inactive text"
arguments:
value: null

- label: "Reads back the optional non-global attribute: InactiveText"
disabled: true
command: "readAttribute"
attribute: "inactive text"
response:
value: null

- label: "Read optional non-global attribute: Polarity"
disabled: true
command: "readAttribute"
attribute: "polarity"
response:
value: 0

- label: "Read optional non-global attribute constraints: Polarity"
disabled: true
command: "readAttribute"
attribute: "polarity"
response:
constraints:
type: enum8

- label:
"Write the default values to optional non-global attribute: Polarity"
disabled: true
command: "writeAttribute"
attribute: "polarity"
arguments:
value: 0
response:
error: 1

- label: "Reads back the optional non-global attribute: Polarity"
disabled: true
command: "readAttribute"
attribute: "polarity"
response:
value: 0

- label: "Read optional non-global attribute: Reliability"
disabled: true
command: "readAttribute"
attribute: "reliability"
response:
value: 0

- label: "Read optional non-global attribute constraints: Reliability"
disabled: true
command: "readAttribute"
attribute: "reliability"
response:
constraints:
type: enum8

- label:
"Write the default values to optional non-global attribute:
Reliability"
disabled: true
command: "writeAttribute"
attribute: "reliability"
arguments:
value: 0

- label: "Reads back the optional non-global attribute: Reliability"
disabled: true
command: "readAttribute"
attribute: "reliability"
response:
value: 0

- label: "Read optional non-global attribute constraints: ApplicationType"
disabled: true
command: "readAttribute"
attribute: "application type"
response:
constraints:
type: uint32
minValue: 0
maxValue: 4294967295

- label:
"Write the default values to optional non-global attribute:
ApplicationType"
disabled: true
command: "writeAttribute"
attribute: "application type"
arguments:
value: 0
response:
error: 1

- label: "Reads back the optional non-global attribute: ApplicationType"
disabled: true
command: "readAttribute"
attribute: "application type"
response:
value: 0
Loading

0 comments on commit 1069066

Please sign in to comment.