mirror of
https://github.com/home-assistant/core.git
synced 2025-07-30 10:48:01 +02:00
Small speed up to checking core state (#107845)
This commit is contained in:
@ -1152,7 +1152,7 @@ async def test_script_restore_last_triggered(hass: HomeAssistant) -> None:
|
||||
State("script.last_triggered", STATE_OFF, {"last_triggered": time}),
|
||||
),
|
||||
)
|
||||
hass.state = CoreState.starting
|
||||
hass.set_state(CoreState.starting)
|
||||
|
||||
assert await async_setup_component(
|
||||
hass,
|
||||
@ -1373,7 +1373,7 @@ async def test_recursive_script_turn_on(
|
||||
await asyncio.wait_for(service_called.wait(), 1)
|
||||
|
||||
# Trigger 1st stage script shutdown
|
||||
hass.state = CoreState.stopping
|
||||
hass.set_state(CoreState.stopping)
|
||||
hass.bus.async_fire("homeassistant_stop")
|
||||
await asyncio.wait_for(stop_scripts_at_shutdown_called.wait(), 1)
|
||||
|
||||
|
Reference in New Issue
Block a user