mirror of
https://github.com/home-assistant/core.git
synced 2025-08-04 05:05:09 +02:00
make sure bootstrap unblocks as well
This commit is contained in:
@@ -13,7 +13,7 @@ from unittest.mock import AsyncMock, Mock, patch
|
|||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
from typing_extensions import Generator
|
||||||
|
|
||||||
from homeassistant import bootstrap, loader, runner
|
from homeassistant import block_async_io, bootstrap, loader, runner
|
||||||
import homeassistant.config as config_util
|
import homeassistant.config as config_util
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
from homeassistant.const import CONF_DEBUG, SIGNAL_BOOTSTRAP_INTEGRATIONS
|
from homeassistant.const import CONF_DEBUG, SIGNAL_BOOTSTRAP_INTEGRATIONS
|
||||||
@@ -55,6 +55,13 @@ async def apply_stop_hass(stop_hass: None) -> None:
|
|||||||
"""Make sure all hass are stopped."""
|
"""Make sure all hass are stopped."""
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.fixture(autouse=True)
|
||||||
|
def unpatch_block_async_io():
|
||||||
|
"""Unpatch block_async_io after each test."""
|
||||||
|
yield
|
||||||
|
block_async_io.disable()
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture(scope="module", autouse=True)
|
@pytest.fixture(scope="module", autouse=True)
|
||||||
def mock_http_start_stop() -> Generator[None]:
|
def mock_http_start_stop() -> Generator[None]:
|
||||||
"""Mock HTTP start and stop."""
|
"""Mock HTTP start and stop."""
|
||||||
|
Reference in New Issue
Block a user