Fix light device trigger test flapping (#39470)

pull/39479/head
J. Nick Koston 2020-08-30 14:34:16 -05:00 committed by GitHub
parent 25f9560fb6
commit 4bbc737954
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -95,6 +95,8 @@ async def test_if_fires_on_state_change(hass, calls):
platform = getattr(hass.components, f"test.{DOMAIN}")
platform.init()
await hass.async_block_till_done()
assert await async_setup_component(hass, DOMAIN, {DOMAIN: {CONF_PLATFORM: "test"}})
await hass.async_block_till_done()
@ -180,6 +182,8 @@ async def test_if_fires_on_state_change_with_for(hass, calls):
platform = getattr(hass.components, f"test.{DOMAIN}")
platform.init()
await hass.async_block_till_done()
assert await async_setup_component(hass, DOMAIN, {DOMAIN: {CONF_PLATFORM: "test"}})
await hass.async_block_till_done()