Add silabs_multiprotocol platform (#92904)

* Add silabs_multiprotocol platform

* Add new files

* Add ZHA tests

* Prevent ZHA from creating database during tests

* Add delay parameter to async_change_channel

* Add the updated dataset to the dataset store

* Allow MultipanProtocol.async_change_channel to return a task

* Notify user about the duration of migration

* Update tests
This commit is contained in:
Erik Montnemery 2023-06-01 12:32:14 +02:00 committed by GitHub
parent 4f153a8f90
commit 15e5cf01bb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 1072 additions and 148 deletions

View file

@ -1,7 +1,7 @@
"""Test fixtures for the Home Assistant Hardware integration."""
from collections.abc import Generator
from typing import Any
from unittest.mock import MagicMock, patch
from unittest.mock import AsyncMock, MagicMock, patch
import pytest
@ -32,6 +32,17 @@ def mock_zha_config_flow_setup() -> Generator[None, None, None]:
yield
@pytest.fixture(autouse=True)
def mock_zha_get_last_network_settings() -> Generator[None, None, None]:
"""Mock zha.api.async_get_last_network_settings."""
with patch(
"homeassistant.components.zha.api.async_get_last_network_settings",
AsyncMock(return_value=None),
):
yield
@pytest.fixture(name="addon_running")
def mock_addon_running(addon_store_info, addon_info):
"""Mock add-on already running."""