Skip to content
代码片段 群组 项目
未验证 提交 d9df1e59 编辑于 作者: Boris Zbarsky's avatar Boris Zbarsky 提交者: GitHub
浏览文件

Add EqualityCommands so that we don't fail parsing YAML files that use it. (#1096)

上级 4e86527e
No related branches found
No related tags found
无相关合并请求
......@@ -23,6 +23,7 @@ const clusterFiles = [
require('./clusters/CommissionerCommands'),
require('./clusters/DelayCommands'),
require('./clusters/DiscoveryCommands'),
require('./clusters/EqualityCommands'),
require('./clusters/LogCommands'),
require('./clusters/SystemCommands'),
];
......
/*
* Copyright (c) 2023 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.
*/
/*
* This file declares test suite utility methods for equality commands.
*
* Each method declared in this file needs to be implemented on a per-language
* basis and allows exposing methods to the test suites that are not part
* of the regular cluster set of APIs.
*/
const kEqualityResponse = {
arguments: [
{ name: 'Equals', type: 'BOOLEAN' },
],
};
const BooleanEquals = {
name: 'BooleanEquals',
arguments: [
{ name: "Value1", type: 'BOOLEAN' },
{ name: "Value2", type: 'BOOLEAN' },
],
responseName: 'EqualityResponse',
response: kEqualityResponse,
};
const SignedNumberEquals = {
name: 'SignedNumberEquals',
arguments: [
{ name: "Value1", type: 'INT64S' },
{ name: "Value2", type: 'INT64S' },
],
responseName: 'EqualityResponse',
response: kEqualityResponse,
};
const UnsignedNumberEquals = {
name: 'UnsignedNumberEquals',
arguments: [
{ name: "Value1", type: 'INT64U' },
{ name: "Value2", type: 'INT64U' },
],
responseName: 'EqualityResponse',
response: kEqualityResponse,
};
const EqualityCommands = {
name: 'EqualityCommands',
commands: [BooleanEquals, SignedNumberEquals, UnsignedNumberEquals],
}
//
// Module exports
//
exports.cluster = EqualityCommands;
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册