mirror of
https://github.com/home-assistant/core.git
synced 2025-07-18 10:47:10 +00:00
Improve type hints in template tests (#123915)
This commit is contained in:
parent
324b6529e8
commit
67f761c0e9
@ -1,5 +1,7 @@
|
|||||||
"""The tests for the Template light platform."""
|
"""The tests for the Template light platform."""
|
||||||
|
|
||||||
|
from typing import Any
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
|
|
||||||
from homeassistant.components import light
|
from homeassistant.components import light
|
||||||
@ -152,7 +154,9 @@ OPTIMISTIC_RGBWW_COLOR_LIGHT_CONFIG = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
async def async_setup_light(hass, count, light_config):
|
async def async_setup_light(
|
||||||
|
hass: HomeAssistant, count: int, light_config: dict[str, Any]
|
||||||
|
) -> None:
|
||||||
"""Do setup of light integration."""
|
"""Do setup of light integration."""
|
||||||
config = {"light": {"platform": "template", "lights": light_config}}
|
config = {"light": {"platform": "template", "lights": light_config}}
|
||||||
|
|
||||||
@ -169,7 +173,9 @@ async def async_setup_light(hass, count, light_config):
|
|||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
async def setup_light(hass, count, light_config):
|
async def setup_light(
|
||||||
|
hass: HomeAssistant, count: int, light_config: dict[str, Any]
|
||||||
|
) -> None:
|
||||||
"""Do setup of light integration."""
|
"""Do setup of light integration."""
|
||||||
await async_setup_light(hass, count, light_config)
|
await async_setup_light(hass, count, light_config)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user