2023-12-21 11:43:11 +00:00
|
|
|
"""Test the Tessie update platform."""
|
|
|
|
from homeassistant.const import STATE_ON
|
|
|
|
from homeassistant.core import HomeAssistant
|
|
|
|
|
|
|
|
from .common import setup_platform
|
|
|
|
|
|
|
|
|
|
|
|
async def test_updates(hass: HomeAssistant) -> None:
|
2023-12-22 09:11:18 +00:00
|
|
|
"""Tests that update entity is correct."""
|
2023-12-21 11:43:11 +00:00
|
|
|
|
|
|
|
assert len(hass.states.async_all("update")) == 0
|
|
|
|
|
|
|
|
await setup_platform(hass)
|
|
|
|
|
|
|
|
assert len(hass.states.async_all("update")) == 1
|
|
|
|
|
|
|
|
assert hass.states.get("update.test").state == STATE_ON
|