Guard for bad device info (#17238)

This commit is contained in:
Paulus Schoutsen authored and Paulus Schoutsen committed 2018-10-08 16:15:40 +02:00
1 parent 3a6eac216c
commit 2e120061b4
2 files changed
+5 -3

No files matched your search

+2
View File
@@ -719,6 +719,8 @@ async def test_device_info_called(hass):
assert await entity_platform.async_setup_entry(config_entry)
await hass.async_block_till_done()
assert len(hass.states.async_entity_ids()) == 2
device = registry.async_get_device({('hue', '1234')}, set())
assert device is not None
assert device.identifiers == {('hue', '1234')}