1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-27 14:31:13 +00:00

Add get_url helper, deprecate base_url (#35224)

This commit is contained in:
Franck Nijhof
2020-05-08 02:29:47 +02:00
committed by GitHub
parent 7e4aa2409f
commit 2223592486
51 changed files with 1416 additions and 198 deletions

View File

@@ -58,6 +58,8 @@ async def test_websocket_core_update(hass, client):
assert hass.config.location_name != "Huis"
assert hass.config.units.name != CONF_UNIT_SYSTEM_IMPERIAL
assert hass.config.time_zone.zone != "America/New_York"
assert hass.config.external_url != "https://www.example.com"
assert hass.config.internal_url != "http://example.com"
await client.send_json(
{
@@ -69,6 +71,8 @@ async def test_websocket_core_update(hass, client):
"location_name": "Huis",
CONF_UNIT_SYSTEM: CONF_UNIT_SYSTEM_IMPERIAL,
"time_zone": "America/New_York",
"external_url": "https://www.example.com",
"internal_url": "http://example.local",
}
)
@@ -83,6 +87,8 @@ async def test_websocket_core_update(hass, client):
assert hass.config.location_name == "Huis"
assert hass.config.units.name == CONF_UNIT_SYSTEM_IMPERIAL
assert hass.config.time_zone.zone == "America/New_York"
assert hass.config.external_url == "https://www.example.com"
assert hass.config.internal_url == "http://example.local"
dt_util.set_default_time_zone(ORIG_TIME_ZONE)