1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-25 05:26:47 +00:00

ZHA component rewrite (#20434)

* rebase reorg

* update coveragerc for now

* sensor cleanup

* remove availability tracking for entities

* finish removing changes from tests

* review comments pass 1

* use asyncio.gather - review comments

* review comments

* cleanup - review comments

* review comments

* review comments

* cleanup

* cleanup - review comments

* review comments

* review comments

* use signal for removal

* correct comment

* remove entities from gateway

* remove dead module

* remove accidently committed file

* use named tuple - review comments

* squash bugs

* squash bugs

* add light and sensor back to coveragerc until % is higher
This commit is contained in:
David F. Mulcahey
2019-02-06 13:33:21 -05:00
committed by GitHub
parent 65a225da75
commit e6cd04d711
22 changed files with 1774 additions and 1591 deletions

View File

@@ -3,9 +3,12 @@ from unittest.mock import patch
import pytest
from homeassistant import config_entries
from homeassistant.components.zha.core.const import (
DOMAIN, DATA_ZHA
DOMAIN, DATA_ZHA, COMPONENTS
)
from homeassistant.components.zha.core.gateway import ZHAGateway
from homeassistant.components.zha.core.gateway import establish_device_mappings
from homeassistant.components.zha.core.listeners \
import populate_listener_registry
from .common import async_setup_entry
@@ -25,6 +28,12 @@ def zha_gateway_fixture(hass):
Create a ZHAGateway object that can be used to interact with as if we
had a real zigbee network running.
"""
populate_listener_registry()
establish_device_mappings()
for component in COMPONENTS:
hass.data[DATA_ZHA][component] = (
hass.data[DATA_ZHA].get(component, {})
)
return ZHAGateway(hass, {})