mirror of
https://github.com/home-assistant/core.git
synced 2025-12-23 12:29:55 +00:00
Migrate homekit_controller tests to use freezegun (#105646)
This commit is contained in:
committed by
GitHub
parent
08ca3678da
commit
d322cb5fdf
@@ -64,9 +64,7 @@ def create_doorbell(accessory):
|
||||
battery.add_char(CharacteristicsTypes.BATTERY_LEVEL)
|
||||
|
||||
|
||||
async def test_remote(
|
||||
hass: HomeAssistant, entity_registry: er.EntityRegistry, utcnow
|
||||
) -> None:
|
||||
async def test_remote(hass: HomeAssistant, entity_registry: er.EntityRegistry) -> None:
|
||||
"""Test that remote is supported."""
|
||||
helper = await setup_test_component(hass, create_remote)
|
||||
|
||||
@@ -109,9 +107,7 @@ async def test_remote(
|
||||
assert state.attributes["event_type"] == "long_press"
|
||||
|
||||
|
||||
async def test_button(
|
||||
hass: HomeAssistant, entity_registry: er.EntityRegistry, utcnow
|
||||
) -> None:
|
||||
async def test_button(hass: HomeAssistant, entity_registry: er.EntityRegistry) -> None:
|
||||
"""Test that a button is correctly enumerated."""
|
||||
helper = await setup_test_component(hass, create_button)
|
||||
entity_id = "event.testdevice_button_1"
|
||||
@@ -148,7 +144,7 @@ async def test_button(
|
||||
|
||||
|
||||
async def test_doorbell(
|
||||
hass: HomeAssistant, entity_registry: er.EntityRegistry, utcnow
|
||||
hass: HomeAssistant, entity_registry: er.EntityRegistry
|
||||
) -> None:
|
||||
"""Test that doorbell service is handled."""
|
||||
helper = await setup_test_component(hass, create_doorbell)
|
||||
|
||||
Reference in New Issue
Block a user