mirror of
https://github.com/home-assistant/core.git
synced 2025-08-03 20:55:10 +02:00
Fix Watergate Water meter volume sensor (#133606)
This commit is contained in:
@@ -56,7 +56,7 @@ class WatergateSensorEntityDescription(SensorEntityDescription):
|
|||||||
DESCRIPTIONS: list[WatergateSensorEntityDescription] = [
|
DESCRIPTIONS: list[WatergateSensorEntityDescription] = [
|
||||||
WatergateSensorEntityDescription(
|
WatergateSensorEntityDescription(
|
||||||
value_fn=lambda data: (
|
value_fn=lambda data: (
|
||||||
data.state.water_meter.duration
|
data.state.water_meter.volume
|
||||||
if data.state and data.state.water_meter
|
if data.state and data.state.water_meter
|
||||||
else None
|
else None
|
||||||
),
|
),
|
||||||
|
@@ -352,7 +352,7 @@
|
|||||||
'last_changed': <ANY>,
|
'last_changed': <ANY>,
|
||||||
'last_reported': <ANY>,
|
'last_reported': <ANY>,
|
||||||
'last_updated': <ANY>,
|
'last_updated': <ANY>,
|
||||||
'state': '100',
|
'state': '1.2',
|
||||||
})
|
})
|
||||||
# ---
|
# ---
|
||||||
# name: test_sensor[sensor.sonic_water_pressure-entry]
|
# name: test_sensor[sensor.sonic_water_pressure-entry]
|
||||||
|
Reference in New Issue
Block a user