Refactor ZHA Zigbee Cluster report configuration (#25589)

* Move ZCL report configs to ZHA core channels.

* Refactor ZCL report configuratopm and cluster binding.

* Tests for ZHA channel configuration.

* Update tests.

* Remove INPUT_BIND_ONLY_CLUSTER ZHA core registry.

We always need bind a cluster, but not always need to configure
attribute reporting. No reporting is done on ZCL "client" clusters.

* Lint

* Black
This commit is contained in:
Alexei Chetroi authored and David F. Mulcahey committed 2019-08-04 18:20:03 -04:00
1 parent 03aec33f9e
commit f7cfe908f7
12 files changed
+245 -199

No files matched your search

+3 -2
View File
@@ -68,12 +68,13 @@ class FakeEndpoint:
def patch_cluster(cluster):
"""Patch a cluster for testing."""
cluster.bind = CoroutineMock(return_value=[0])
cluster.configure_reporting = CoroutineMock(return_value=[0])
cluster.deserialize = Mock()
cluster.handle_cluster_request = Mock()
cluster.handle_cluster_general_request = Mock()
cluster.read_attributes = CoroutineMock()
cluster.read_attributes_raw = Mock()
cluster.read_attributes = Mock()
cluster.unbind = Mock()
cluster.unbind = CoroutineMock(return_value=[0])
class FakeDevice: