1
0
mirror of https://github.com/home-assistant/core.git synced 2026-05-08 09:38:58 +01:00

Remove name for Shelly gas valve (gen1) entity (#157490)

This commit is contained in:
Maciej Bieniek
2025-11-28 15:26:17 +01:00
committed by GitHub
parent 1a1b50ef1a
commit ca35102138
3 changed files with 8 additions and 1 deletions
@@ -592,6 +592,11 @@
"beta_firmware": {
"name": "Beta firmware"
}
},
"valve": {
"gas_valve": {
"name": "Valve"
}
}
},
"exceptions": {
+1 -1
View File
@@ -49,7 +49,7 @@ class RpcValveDescription(RpcEntityDescription, ValveEntityDescription):
BLOCK_VALVES: dict[tuple[str, str], BlockValveDescription] = {
("valve", "valve"): BlockValveDescription(
key="valve|valve",
name="Valve",
translation_key="gas_valve",
available=lambda block: block.valve not in ("failure", "checking"),
removal_condition=lambda _, block: block.valve in ("not_connected", "unknown"),
models={MODEL_GAS},
+2
View File
@@ -50,6 +50,8 @@ async def test_block_device_gas_valve(
assert (entry := entity_registry.async_get(entity_id))
assert entry.unique_id == "123456789ABC-valve_0-valve"
assert entry.name is None
assert entry.translation_key == "gas_valve"
assert (state := hass.states.get(entity_id))
assert state.state == ValveState.CLOSED