Add support for ZHA door locks #2 (#24344)

* Add support for DoorLock cluster
* Add test for zha lock
* Change lock_state report to REPORT_CONFIG_IMMEDIATE
* Update channel command wrapper to return the entire result
This allows for return values other than result[1]

* Fix tests
* Fix lint
* Update DoorLock test to work with updated zigpy schema
* Fix lint
* Fix unlock test
This commit is contained in:
presslab-us authored and Alexei Chetroi committed 2019-06-07 11:16:33 -04:00
1 parent 592d30d495
commit cb460a85ba
11 files changed
+305 -34

No files matched your search

@@ -5,6 +5,7 @@ import logging
from homeassistant.components.binary_sensor import DOMAIN as BINARY_SENSOR
from homeassistant.components.fan import DOMAIN as FAN
from homeassistant.components.light import DOMAIN as LIGHT
from homeassistant.components.lock import DOMAIN as LOCK
from homeassistant.components.sensor import DOMAIN as SENSOR
from homeassistant.components.switch import DOMAIN as SWITCH
@@ -27,6 +28,7 @@ COMPONENTS = (
BINARY_SENSOR,
FAN,
LIGHT,
LOCK,
SENSOR,
SWITCH,
)
@@ -92,6 +94,7 @@ ZONE_CHANNEL = ZONE = 'ias_zone'
ELECTRICAL_MEASUREMENT_CHANNEL = 'electrical_measurement'
POWER_CONFIGURATION_CHANNEL = 'power'
EVENT_RELAY_CHANNEL = 'event_relay'
DOORLOCK_CHANNEL = 'door_lock'
SIGNAL_ATTR_UPDATED = 'attribute_updated'
SIGNAL_MOVE_LEVEL = "move_level"