Adjust zwave_js tests which create devices (#98213)

This commit is contained in:
Erik Montnemery 2023-08-10 18:27:22 +02:00 committed by GitHub
parent 49011f0158
commit f1d4a4bd26
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -9,12 +9,16 @@ from homeassistant.components.zwave_js.helpers import (
from homeassistant.core import HomeAssistant
from homeassistant.helpers import area_registry as ar, device_registry as dr
from tests.common import MockConfigEntry
async def test_async_get_node_status_sensor_entity_id(hass: HomeAssistant) -> None:
"""Test async_get_node_status_sensor_entity_id for non zwave_js device."""
dev_reg = dr.async_get(hass)
config_entry = MockConfigEntry()
config_entry.add_to_hass(hass)
device = dev_reg.async_get_or_create(
config_entry_id="123",
config_entry_id=config_entry.entry_id,
identifiers={("test", "test")},
)
assert async_get_node_status_sensor_entity_id(hass, device.id) is None