Improve dimmer support (#62)

* discover dimmers properly

* fix circular import, hopefully

* add is_color to SmartDevice API

* allow changing the dimming without implicitly turning the device on

* Add tests for device type handling for discovery data, make sure new fixtures are added to categories inside conftest
This commit is contained in:
Teemu R
2020-05-20 21:17:33 +02:00
committed by GitHub
parent e37244de0f
commit 012436c494
7 changed files with 71 additions and 8 deletions

View File

@@ -249,8 +249,8 @@ def success(target, cmd, res):
class FakeTransportProtocol(TPLinkSmartHomeProtocol):
def __init__(self, info, invalid=False):
# TODO remove invalid when removing the old tests.
def __init__(self, info):
self.discovery_data = info
proto = FakeTransportProtocol.baseproto
for target in info:
# print("target %s" % target)