mirror of
https://github.com/home-assistant/core.git
synced 2025-11-09 02:49:40 +00:00
Use local time instead of UTC time as default backup filenames (#100959)
Use local time instead of UTC for the backup name
This commit is contained in:
committed by
GitHub
parent
01b5854968
commit
96151e7faa
@@ -548,7 +548,7 @@ async def test_service_calls(
|
||||
|
||||
assert aioclient_mock.call_count == 30
|
||||
assert aioclient_mock.mock_calls[-1][2] == {
|
||||
"name": "2021-11-13 11:48:00",
|
||||
"name": "2021-11-13 03:48:00",
|
||||
"homeassistant": True,
|
||||
"addons": ["test"],
|
||||
"folders": ["ssl"],
|
||||
@@ -605,6 +605,24 @@ async def test_service_calls(
|
||||
await hass.async_block_till_done()
|
||||
|
||||
assert aioclient_mock.call_count == 34
|
||||
assert aioclient_mock.mock_calls[-1][2] == {
|
||||
"name": "2021-11-13 03:48:00",
|
||||
"location": None,
|
||||
}
|
||||
|
||||
# check backup with different timezone
|
||||
await hass.config.async_update(time_zone="Europe/London")
|
||||
|
||||
await hass.services.async_call(
|
||||
"hassio",
|
||||
"backup_full",
|
||||
{
|
||||
"location": "/backup",
|
||||
},
|
||||
)
|
||||
await hass.async_block_till_done()
|
||||
|
||||
assert aioclient_mock.call_count == 36
|
||||
assert aioclient_mock.mock_calls[-1][2] == {
|
||||
"name": "2021-11-13 11:48:00",
|
||||
"location": None,
|
||||
|
||||
Reference in New Issue
Block a user