mirror of
https://github.com/basnijholt/adaptive-lighting.git
synced 2026-09-11 22:34:04 +02:00
Fix adaptive_lighting.change_switch_settings service (#712)
* Fix adaptive_lighting.change_switch_settings service Closes #623 * filter defaults * fix mutable * Revert debugging logs
This commit is contained in:
parent
d2c6811e63
commit
cb9ae39ee4
2 changed files with 19 additions and 8 deletions
|
|
@ -1353,6 +1353,12 @@ async def test_change_switch_settings_service(hass):
|
|||
await change_switch_settings(**{CONF_USE_DEFAULTS: "current"})
|
||||
assert switch._sun_light_settings.min_color_temp == 2000
|
||||
|
||||
# testing with "configuration" and setting a new value
|
||||
await change_switch_settings(
|
||||
**{CONF_USE_DEFAULTS: "configuration", CONF_MIN_COLOR_TEMP: 3000}
|
||||
)
|
||||
assert switch._sun_light_settings.min_color_temp == 3000
|
||||
|
||||
# testing with "configuration" should revert back to 2500
|
||||
await change_switch_settings(**{CONF_USE_DEFAULTS: "configuration"})
|
||||
assert switch._sun_light_settings.min_color_temp == 2500
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue