Improve hass_ws_client type hint in tests (#89703)
This commit is contained in:
parent
1bc4802c04
commit
71dc98a39c
17 changed files with 52 additions and 71 deletions
|
@ -1,18 +1,18 @@
|
|||
"""Tests for the Backup integration."""
|
||||
from collections.abc import Awaitable, Callable
|
||||
from unittest.mock import patch
|
||||
|
||||
from aiohttp import ClientWebSocketResponse
|
||||
import pytest
|
||||
|
||||
from homeassistant.core import HomeAssistant
|
||||
|
||||
from .common import TEST_BACKUP, setup_backup_integration
|
||||
|
||||
from tests.typing import WebSocketGenerator
|
||||
|
||||
|
||||
async def test_info(
|
||||
hass: HomeAssistant,
|
||||
hass_ws_client: Callable[[HomeAssistant], Awaitable[ClientWebSocketResponse]],
|
||||
hass_ws_client: WebSocketGenerator,
|
||||
) -> None:
|
||||
"""Test getting backup info."""
|
||||
await setup_backup_integration(hass)
|
||||
|
@ -34,7 +34,7 @@ async def test_info(
|
|||
|
||||
async def test_remove(
|
||||
hass: HomeAssistant,
|
||||
hass_ws_client: Callable[[HomeAssistant], Awaitable[ClientWebSocketResponse]],
|
||||
hass_ws_client: WebSocketGenerator,
|
||||
caplog: pytest.LogCaptureFixture,
|
||||
) -> None:
|
||||
"""Test removing a backup file."""
|
||||
|
@ -55,7 +55,7 @@ async def test_remove(
|
|||
|
||||
async def test_generate(
|
||||
hass: HomeAssistant,
|
||||
hass_ws_client: Callable[[HomeAssistant], Awaitable[ClientWebSocketResponse]],
|
||||
hass_ws_client: WebSocketGenerator,
|
||||
) -> None:
|
||||
"""Test removing a backup file."""
|
||||
await setup_backup_integration(hass)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue