Issue #478 vtherm doesn't follow underlying (#548)

* Dispatch test_bugs into each own VTherm type tests

* Local tests ok

* With testus ok.

---------

Co-authored-by: Jean-Marc Collin <jean-marc.collin-extern@renault.com>
This commit is contained in:
Jean-Marc Collin
2024-10-13 11:30:04 +02:00
committed by GitHub
parent 1334bdbd8f
commit 73a9ca4e53
13 changed files with 1028 additions and 960 deletions

View File

@@ -488,6 +488,7 @@ class UnderlyingClimate(UnderlyingEntity):
entity_id=climate_entity_id,
)
self._underlying_climate = None
self._last_sent_temperature = None
def find_underlying_climate(self) -> ClimateEntity:
"""Find the underlying climate entity"""
@@ -637,6 +638,13 @@ class UnderlyingClimate(UnderlyingEntity):
data,
)
self._last_sent_temperature = target_temp
@property
def last_sent_temperature(self) -> float | None:
"""Get the last send temperature. None if no temperature have been sent yet"""
return self._last_sent_temperature
@property
def hvac_action(self) -> HVACAction | None:
"""Get the hvac action of the underlying"""
@@ -721,6 +729,13 @@ class UnderlyingClimate(UnderlyingEntity):
return 15
return self._underlying_climate.target_temperature_low
@property
def target_temperature(self) -> float:
"""Get the target_temperature"""
if not self.is_initialized:
return None
return self._underlying_climate.target_temperature
@property
def is_aux_heat(self) -> bool:
"""Get the is_aux_heat"""