Skip to content

Commit

Permalink
Add ECO temp to Generic Thermostat (#110471)
Browse files Browse the repository at this point in the history
feat: add ECO temp to Generic Thermostat.
  • Loading branch information
Minims committed Feb 24, 2024
1 parent 777428c commit 597118d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions homeassistant/components/generic_thermostat/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
PRESET_ACTIVITY,
PRESET_AWAY,
PRESET_COMFORT,
PRESET_ECO,
PRESET_HOME,
PRESET_NONE,
PRESET_SLEEP,
Expand Down Expand Up @@ -86,6 +87,7 @@
for p in (
PRESET_AWAY,
PRESET_COMFORT,
PRESET_ECO,
PRESET_HOME,
PRESET_SLEEP,
PRESET_ACTIVITY,
Expand Down
5 changes: 5 additions & 0 deletions tests/components/generic_thermostat/test_climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
PRESET_ACTIVITY,
PRESET_AWAY,
PRESET_COMFORT,
PRESET_ECO,
PRESET_HOME,
PRESET_NONE,
PRESET_SLEEP,
Expand Down Expand Up @@ -225,6 +226,7 @@ async def setup_comp_2(hass):
"sleep_temp": 17,
"home_temp": 19,
"comfort_temp": 20,
"eco_temp": 18,
"activity_temp": 21,
"initial_hvac_mode": HVACMode.HEAT,
}
Expand Down Expand Up @@ -312,6 +314,7 @@ async def test_set_target_temp(hass: HomeAssistant, setup_comp_2) -> None:
(PRESET_NONE, 23),
(PRESET_AWAY, 16),
(PRESET_COMFORT, 20),
(PRESET_ECO, 18),
(PRESET_HOME, 19),
(PRESET_SLEEP, 17),
(PRESET_ACTIVITY, 21),
Expand All @@ -331,6 +334,7 @@ async def test_set_away_mode(hass: HomeAssistant, setup_comp_2, preset, temp) ->
(PRESET_NONE, 23),
(PRESET_AWAY, 16),
(PRESET_COMFORT, 20),
(PRESET_ECO, 18),
(PRESET_HOME, 19),
(PRESET_SLEEP, 17),
(PRESET_ACTIVITY, 21),
Expand Down Expand Up @@ -358,6 +362,7 @@ async def test_set_away_mode_and_restore_prev_temp(
(PRESET_NONE, 23),
(PRESET_AWAY, 16),
(PRESET_COMFORT, 20),
(PRESET_ECO, 18),
(PRESET_HOME, 19),
(PRESET_SLEEP, 17),
(PRESET_ACTIVITY, 21),
Expand Down

0 comments on commit 597118d

Please sign in to comment.