Use registry fixtures in tests (s) (#118295)

This commit is contained in:
epenet 2024-05-28 15:41:03 +02:00 committed by GitHub
parent 90500c4b97
commit e58d060f82
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
56 changed files with 377 additions and 318 deletions

View file

@ -18,7 +18,10 @@ from .conftest import setup_platform
async def test_entity_and_device_attributes(
hass: HomeAssistant, device_factory
hass: HomeAssistant,
device_registry: dr.DeviceRegistry,
entity_registry: er.EntityRegistry,
device_factory,
) -> None:
"""Test the attributes of the entity are correct."""
# Arrange
@ -33,8 +36,6 @@ async def test_entity_and_device_attributes(
Attribute.mnfv: "v7.89",
},
)
entity_registry = er.async_get(hass)
device_registry = dr.async_get(hass)
# Act
await setup_platform(hass, SWITCH_DOMAIN, devices=[device])
# Assert