mirror of
https://github.com/home-assistant/core
synced 2024-09-09 12:51:22 +02:00
Add value ID to zwave_js device diagnostics (#78015)
This commit is contained in:
parent
1802ecfc24
commit
37631d2017
@ -123,6 +123,7 @@ def get_device_entities(
|
||||
"entity_category": entry.entity_category,
|
||||
"supported_features": entry.supported_features,
|
||||
"unit_of_measurement": entry.unit_of_measurement,
|
||||
"value_id": value_id,
|
||||
"primary_value": primary_value_data,
|
||||
}
|
||||
entities.append(entity)
|
||||
|
@ -152,6 +152,7 @@ async def test_device_diagnostics_missing_primary_value(
|
||||
x for x in diagnostics_data["entities"] if x["entity_id"] == entity_id
|
||||
)
|
||||
|
||||
assert air_entity["value_id"] == value.value_id
|
||||
assert air_entity["primary_value"] == {
|
||||
"command_class": value.command_class,
|
||||
"command_class_name": value.command_class_name,
|
||||
@ -189,4 +190,5 @@ async def test_device_diagnostics_missing_primary_value(
|
||||
x for x in diagnostics_data["entities"] if x["entity_id"] == entity_id
|
||||
)
|
||||
|
||||
assert air_entity["value_id"] == value.value_id
|
||||
assert air_entity["primary_value"] is None
|
||||
|
Loading…
Reference in New Issue
Block a user