Use new enums in litterrobot tests (#62515)
* Use new enums in litterrobot tests * Code review: swap == for is
This commit is contained in:
parent
d3d6965ba0
commit
a7ef983a31
4 changed files with 12 additions and 19 deletions
|
@ -4,14 +4,10 @@ from unittest.mock import MagicMock
|
|||
from freezegun import freeze_time
|
||||
|
||||
from homeassistant.components.button import DOMAIN as BUTTON_DOMAIN, SERVICE_PRESS
|
||||
from homeassistant.const import (
|
||||
ATTR_ENTITY_ID,
|
||||
ATTR_ICON,
|
||||
ENTITY_CATEGORY_CONFIG,
|
||||
STATE_UNKNOWN,
|
||||
)
|
||||
from homeassistant.const import ATTR_ENTITY_ID, ATTR_ICON, STATE_UNKNOWN
|
||||
from homeassistant.core import HomeAssistant
|
||||
from homeassistant.helpers import entity_registry as er
|
||||
from homeassistant.helpers.entity import EntityCategory
|
||||
|
||||
from .conftest import setup_integration
|
||||
|
||||
|
@ -31,7 +27,7 @@ async def test_button(hass: HomeAssistant, mock_account: MagicMock) -> None:
|
|||
|
||||
entry = entity_registry.async_get(BUTTON_ENTITY)
|
||||
assert entry
|
||||
assert entry.entity_category == ENTITY_CATEGORY_CONFIG
|
||||
assert entry.entity_category is EntityCategory.CONFIG
|
||||
|
||||
await hass.services.async_call(
|
||||
BUTTON_DOMAIN,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue