1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 21:06:19 +00:00

Fix flux_led reloading too quickly after an operating mode change (#64591)

This commit is contained in:
J. Nick Koston
2022-01-22 18:56:38 -10:00
committed by GitHub
parent cdf7742c3e
commit d5211c12b0
2 changed files with 28 additions and 15 deletions

View File

@@ -31,6 +31,13 @@ from . import (
from tests.common import MockConfigEntry
@pytest.fixture(autouse=True)
def no_wait_on_state_change():
"""Disable waiting for state change in tests."""
with patch("homeassistant.components.flux_led.select.STATE_CHANGE_LATENCY", 0):
yield
async def test_switch_power_restore_state(hass: HomeAssistant) -> None:
"""Test a smart plug power restore state."""
config_entry = MockConfigEntry(