diff options
author | Surender Kodam <surenderk@google.com> | 2016-04-22 09:45:58 -0700 |
---|---|---|
committer | Surender Kodam <surenderk@google.com> | 2016-04-22 18:52:35 +0000 |
commit | eed244673d7ce446ea4bdf2ed3157f03d7e973a8 (patch) | |
tree | 6c98507ed0b39b8249cad5d87a92428fc3321268 /tests_schema/daemon/testdevice/standard_traits.h | |
parent | 5e67ce2496fc5fc3655ac1c728e94626c3e8f6c9 (diff) | |
download | libweave-eed244673d7ce446ea4bdf2ed3157f03d7e973a8.tar.gz |
Add volume trait to the test_schema device.
Change-Id: I27d9575ad4710d0f9a8ad9b47cb800afd44c80fd
Reviewed-on: https://weave-review.googlesource.com/3252
Reviewed-by: Alex Vakulenko <avakulenko@google.com>
Diffstat (limited to 'tests_schema/daemon/testdevice/standard_traits.h')
-rw-r--r-- | tests_schema/daemon/testdevice/standard_traits.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/tests_schema/daemon/testdevice/standard_traits.h b/tests_schema/daemon/testdevice/standard_traits.h index c63c5fe..27586f8 100644 --- a/tests_schema/daemon/testdevice/standard_traits.h +++ b/tests_schema/daemon/testdevice/standard_traits.h @@ -196,6 +196,35 @@ const char kTraits[] = R"({ } } } + }, + "volume": { + "commands": { + "setConfig": { + "minimalRole": "user", + "parameters": { + "volume": { + "type": "integer", + "minimum": 0, + "maximum": 100 + }, + "isMuted": { + "type": "boolean" + } + } + } + }, + "state": { + "volume": { + "isRequired": true, + "type": "integer", + "minimum": 0, + "maximum": 100 + }, + "isMuted": { + "isRequired": true, + "type": "boolean" + } + } } })"; @@ -203,6 +232,7 @@ const char kDefaultState[] = R"({ "lock":{"isLockingSupported": true}, "onOff":{"state": "on"}, "brightness":{"brightness": 0.0}, + "volume":{"isMuted": true}, "colorTemp":{"colorTemp": 0}, "colorXy": { "colorSetting": {"colorX": 0.0, "colorY": 0.0}, |