mirror of
https://github.com/home-assistant/core
synced 2024-07-15 09:42:11 +02:00
Map missing preset mapping for heat mode "ready" in smarttub (#106856)
This commit is contained in:
parent
b074b23979
commit
370345ce2b
@ -23,11 +23,13 @@ from .const import DEFAULT_MAX_TEMP, DEFAULT_MIN_TEMP, DOMAIN, SMARTTUB_CONTROLL
|
||||
from .entity import SmartTubEntity
|
||||
|
||||
PRESET_DAY = "day"
|
||||
PRESET_READY = "ready"
|
||||
|
||||
PRESET_MODES = {
|
||||
Spa.HeatMode.AUTO: PRESET_NONE,
|
||||
Spa.HeatMode.ECONOMY: PRESET_ECO,
|
||||
Spa.HeatMode.DAY: PRESET_DAY,
|
||||
Spa.HeatMode.READY: PRESET_READY,
|
||||
}
|
||||
|
||||
HEAT_MODES = {v: k for k, v in PRESET_MODES.items()}
|
||||
|
@ -58,7 +58,7 @@ async def test_thermostat_update(
|
||||
assert state.attributes[ATTR_TEMPERATURE] == 39
|
||||
assert state.attributes[ATTR_MAX_TEMP] == DEFAULT_MAX_TEMP
|
||||
assert state.attributes[ATTR_MIN_TEMP] == DEFAULT_MIN_TEMP
|
||||
assert state.attributes[ATTR_PRESET_MODES] == ["none", "eco", "day"]
|
||||
assert state.attributes[ATTR_PRESET_MODES] == ["none", "eco", "day", "ready"]
|
||||
|
||||
await hass.services.async_call(
|
||||
CLIMATE_DOMAIN,
|
||||
|
Loading…
Reference in New Issue
Block a user