mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 11:17:21 +00:00
Fix ecobee test helper (#126587)
This commit is contained in:
parent
3c9f51fbbd
commit
ce70f4ebac
@ -5,7 +5,6 @@ from unittest.mock import patch
|
|||||||
from homeassistant.components.ecobee.const import CONF_REFRESH_TOKEN, DOMAIN
|
from homeassistant.components.ecobee.const import CONF_REFRESH_TOKEN, DOMAIN
|
||||||
from homeassistant.const import CONF_API_KEY
|
from homeassistant.const import CONF_API_KEY
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
from homeassistant.setup import async_setup_component
|
|
||||||
|
|
||||||
from tests.common import MockConfigEntry
|
from tests.common import MockConfigEntry
|
||||||
|
|
||||||
@ -25,8 +24,7 @@ async def setup_platform(
|
|||||||
)
|
)
|
||||||
mock_entry.add_to_hass(hass)
|
mock_entry.add_to_hass(hass)
|
||||||
|
|
||||||
with patch("homeassistant.components.ecobee.const.PLATFORMS", [platform]):
|
with patch("homeassistant.components.ecobee.PLATFORMS", [platform]):
|
||||||
assert await async_setup_component(hass, DOMAIN, {})
|
await hass.config_entries.async_setup(mock_entry.entry_id)
|
||||||
await hass.async_block_till_done()
|
await hass.async_block_till_done()
|
||||||
|
|
||||||
return mock_entry
|
return mock_entry
|
||||||
|
Loading…
x
Reference in New Issue
Block a user