mirror of
https://github.com/home-assistant/core.git
synced 2025-05-01 04:37:52 +00:00
Fix powerwall display of actual remaining battery, instead of reserved capacity (#142391)
This commit is contained in:
parent
1892c8fa62
commit
c8972a2234
@ -297,7 +297,6 @@ class PowerWallBackupReserveSensor(PowerWallEntity, SensorEntity):
|
|||||||
_attr_translation_key = "backup_reserve"
|
_attr_translation_key = "backup_reserve"
|
||||||
_attr_state_class = SensorStateClass.MEASUREMENT
|
_attr_state_class = SensorStateClass.MEASUREMENT
|
||||||
_attr_native_unit_of_measurement = PERCENTAGE
|
_attr_native_unit_of_measurement = PERCENTAGE
|
||||||
_attr_device_class = SensorDeviceClass.BATTERY
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def unique_id(self) -> str:
|
def unique_id(self) -> str:
|
||||||
|
@ -118,7 +118,6 @@ async def test_sensors(hass: HomeAssistant, device_registry: dr.DeviceRegistry)
|
|||||||
expected_attributes = {
|
expected_attributes = {
|
||||||
"unit_of_measurement": PERCENTAGE,
|
"unit_of_measurement": PERCENTAGE,
|
||||||
"friendly_name": "MySite Backup reserve",
|
"friendly_name": "MySite Backup reserve",
|
||||||
"device_class": "battery",
|
|
||||||
}
|
}
|
||||||
# Only test for a subset of attributes in case
|
# Only test for a subset of attributes in case
|
||||||
# HA changes the implementation and a new one appears
|
# HA changes the implementation and a new one appears
|
||||||
|
Loading…
x
Reference in New Issue
Block a user