Update home zone when core config updated (#24237)
* Update home zone when core config updated * Lint
This commit is contained in:
1 parent
b4374c8c4c
commit
b90636f640
7 files changed
+57
-31
No files matched your search
+3
-3
@@ -955,7 +955,7 @@ async def test_event_on_update(hass, hass_storage):
|
||||
|
||||
assert hass.config.latitude != 12
|
||||
|
||||
await hass.config.update(latitude=12)
|
||||
await hass.config.async_update(latitude=12)
|
||||
await hass.async_block_till_done()
|
||||
|
||||
assert hass.config.latitude == 12
|
||||
@@ -963,10 +963,10 @@ async def test_event_on_update(hass, hass_storage):
|
||||
assert events[0].data == {'latitude': 12}
|
||||
|
||||
|
||||
def test_bad_timezone_raises_value_error(hass):
|
||||
async def test_bad_timezone_raises_value_error(hass):
|
||||
"""Test bad timezone raises ValueError."""
|
||||
with pytest.raises(ValueError):
|
||||
hass.config.set_time_zone('not_a_timezone')
|
||||
await hass.config.async_update(time_zone='not_a_timezone')
|
||||
|
||||
|
||||
@patch('homeassistant.core.monotonic')
|
||||
|
||||
Reference in new issue
Block a user