Migrate homekit_controller tests to use freezegun (#105646)

This commit is contained in:
Jan-Philipp Benecke
2023-12-13 19:37:51 +01:00
committed by GitHub
parent 08ca3678da
commit d322cb5fdf
22 changed files with 152 additions and 197 deletions

View File

@@ -30,7 +30,7 @@ def create_switch_with_spray_level(accessory):
async def test_migrate_unique_id(
hass: HomeAssistant, entity_registry: er.EntityRegistry, utcnow
hass: HomeAssistant, entity_registry: er.EntityRegistry
) -> None:
"""Test a we can migrate a number unique id."""
aid = get_next_aid()
@@ -48,7 +48,7 @@ async def test_migrate_unique_id(
)
async def test_read_number(hass: HomeAssistant, utcnow) -> None:
async def test_read_number(hass: HomeAssistant) -> None:
"""Test a switch service that has a sensor characteristic is correctly handled."""
helper = await setup_test_component(hass, create_switch_with_spray_level)
@@ -74,7 +74,7 @@ async def test_read_number(hass: HomeAssistant, utcnow) -> None:
assert state.state == "5"
async def test_write_number(hass: HomeAssistant, utcnow) -> None:
async def test_write_number(hass: HomeAssistant) -> None:
"""Test a switch service that has a sensor characteristic is correctly handled."""
helper = await setup_test_component(hass, create_switch_with_spray_level)