Add missing hass type hint in component tests (y) (#124286)

pull/124297/head
epenet 2024-08-20 12:55:14 +02:00 committed by GitHub
parent 69a5605551
commit 14775c822f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 1 deletions

View File

@ -1,6 +1,7 @@
"""Tests for the yandex transport platform.""" """Tests for the yandex transport platform."""
import json import json
from typing import Any
from unittest.mock import AsyncMock, patch from unittest.mock import AsyncMock, patch
import pytest import pytest
@ -76,7 +77,9 @@ SUBURBAN_RESULT_STATE = dt_util.utc_from_timestamp(1634984640).isoformat(
) )
async def assert_setup_sensor(hass, config, count=1): async def assert_setup_sensor(
hass: HomeAssistant, config: dict[str, Any], count: int = 1
) -> None:
"""Set up the sensor and assert it's been created.""" """Set up the sensor and assert it's been created."""
with assert_setup_component(count): with assert_setup_component(count):
assert await async_setup_component(hass, sensor.DOMAIN, config) assert await async_setup_component(hass, sensor.DOMAIN, config)