Fix hw_version not updating from an entity device_info (#62254)
parent
8d6763eaad
commit
a40549c1b9
|
@ -474,6 +474,7 @@ class EntityPlatform:
|
|||
"name",
|
||||
"suggested_area",
|
||||
"sw_version",
|
||||
"hw_version",
|
||||
"via_device",
|
||||
):
|
||||
if key in device_info:
|
||||
|
|
|
@ -838,6 +838,7 @@ async def test_device_info_called(hass):
|
|||
"model": "test-model",
|
||||
"name": "test-name",
|
||||
"sw_version": "test-sw",
|
||||
"hw_version": "test-hw",
|
||||
"suggested_area": "Heliport",
|
||||
"entry_type": dr.DeviceEntryType.SERVICE,
|
||||
"via_device": ("hue", "via-id"),
|
||||
|
@ -869,6 +870,7 @@ async def test_device_info_called(hass):
|
|||
assert device.name == "test-name"
|
||||
assert device.suggested_area == "Heliport"
|
||||
assert device.sw_version == "test-sw"
|
||||
assert device.hw_version == "test-hw"
|
||||
assert device.via_device_id == via.id
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue