mirror of
https://github.com/esphome/esphome.git
synced 2026-05-28 04:55:48 +08:00
[tests] Fix flaky host_mode_climate_basic_state by ignoring prior MEMORY state
The fixture shares the `host-climate-test` build dir with host_mode_climate_control.yaml. When the control test runs first and leaves the thermostat in HEAT mode, MEMORY restore on the next basic_state boot picked up HEAT and the initial-state assertion failed (`assert ClimateMode.HEAT == ClimateMode.OFF`).
This commit is contained in:
@@ -28,6 +28,10 @@ climate:
|
|||||||
min_temperature: 15.0
|
min_temperature: 15.0
|
||||||
max_temperature: 32.0
|
max_temperature: 32.0
|
||||||
temperature_step: 0.1
|
temperature_step: 0.1
|
||||||
|
# Don't restore previous state from flash — this fixture shares the
|
||||||
|
# `host-climate-test` build dir with host_mode_climate_control.yaml, so a
|
||||||
|
# prior run of that test could leave the thermostat in HEAT/COOL.
|
||||||
|
on_boot_restore_from: default_preset
|
||||||
default_preset: home
|
default_preset: home
|
||||||
preset:
|
preset:
|
||||||
- name: "away"
|
- name: "away"
|
||||||
|
|||||||
Reference in New Issue
Block a user