Skip to content

Commit

Permalink
Adding Illuminance Measurement yaml tests (#11702)
Browse files Browse the repository at this point in the history
  • Loading branch information
wystans authored and pull[bot] committed Feb 6, 2023
1 parent 03062c3 commit 1081976
Show file tree
Hide file tree
Showing 5 changed files with 262 additions and 0 deletions.
5 changes: 5 additions & 0 deletions examples/chip-tool/templates/tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ function getTests()
'Test_TC_FLW_2_2',
];

const IlluminanceMeasurement = [
'Test_TC_ILL_1_1',
];

const OccupancySensing = [
'Test_TC_OCC_1_1',
'Test_TC_OCC_2_1',
Expand Down Expand Up @@ -199,6 +203,7 @@ function getTests()
DeviceManagement, //
ElectricalMeasurement, //
FlowMeasurement, //
IlluminanceMeasurement, //
LevelControl, //
MediaControl, //
OccupancySensing, //
Expand Down
42 changes: 42 additions & 0 deletions src/app/tests/suites/certification/Test_TC_ILL_1_1.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# 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: 71.1.1. [TC-ILL-1.1] Global attributes with server as DUT

config:
cluster: "Illuminance Measurement"
endpoint: 1

tests:
- label: "read the global attribute: ClusterRevision"
command: "readAttribute"
attribute: "ClusterRevision"
response:
value: 2

- label:
"write the default values to mandatory global attribute:
ClusterRevision"
command: "writeAttribute"
attribute: "ClusterRevision"
arguments:
value: 1
response:
error: 1

- label: "reads back global attribute: ClusterRevision"
command: "readAttribute"
attribute: "ClusterRevision"
response:
value: 2
5 changes: 5 additions & 0 deletions src/darwin/Framework/CHIP/templates/tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,10 @@ function getTests()
'Test_TC_FLW_2_2',
];

const IlluminanceMeasurement = [
'Test_TC_ILL_1_1',
];

const OccupancySensing = [
'Test_TC_OCC_1_1',
'Test_TC_OCC_2_1',
Expand Down Expand Up @@ -182,6 +186,7 @@ function getTests()
DeviceManagement, //
ElectricalMeasurement, //
FlowMeasurement, //
IlluminanceMeasurement, //
LevelControl, //
MediaControl, //
OccupancySensing, //
Expand Down
71 changes: 71 additions & 0 deletions src/darwin/Framework/CHIPTests/CHIPClustersTests.m

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

139 changes: 139 additions & 0 deletions zzz_generated/chip-tool/zap-generated/test/Commands.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 1081976

Please sign in to comment.