1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 21:06:19 +00:00

Fix ecobee flaky test (#25019)

This commit is contained in:
Paulus Schoutsen
2019-07-08 13:10:01 -07:00
committed by GitHub
parent 662e0dde80
commit 0b7a901c81
2 changed files with 10 additions and 8 deletions

View File

@@ -1,4 +1,5 @@
"""Support for Ecobee Thermostats."""
import collections
import logging
from typing import Optional
@@ -31,13 +32,14 @@ PRESET_HOLD_NEXT_TRANSITION = 'next_transition'
PRESET_HOLD_INDEFINITE = 'indefinite'
AWAY_MODE = 'awayMode'
ECOBEE_HVAC_TO_HASS = {
'auxHeatOnly': HVAC_MODE_HEAT,
'heat': HVAC_MODE_HEAT,
'cool': HVAC_MODE_COOL,
'off': HVAC_MODE_OFF,
'auto': HVAC_MODE_AUTO,
}
# Order matters, because for reverse mapping we don't want to map HEAT to AUX
ECOBEE_HVAC_TO_HASS = collections.OrderedDict([
('heat', HVAC_MODE_HEAT),
('cool', HVAC_MODE_COOL),
('auto', HVAC_MODE_AUTO),
('off', HVAC_MODE_OFF),
('auxHeatOnly', HVAC_MODE_HEAT),
])
PRESET_TO_ECOBEE_HOLD = {
PRESET_HOLD_NEXT_TRANSITION: 'nextTransition',