1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 12:59:34 +00:00

Collection of core tests improvements (#33757)

* Collection of core tests improvements

* Added some more

* Fix aiohttp client response release
This commit is contained in:
Franck Nijhof
2020-04-07 18:33:23 +02:00
committed by GitHub
parent 1f7803c541
commit 60bc517d01
12 changed files with 302 additions and 343 deletions

View File

@@ -1,6 +1,5 @@
"""Test config utils."""
# pylint: disable=protected-access
import asyncio
from collections import OrderedDict
import copy
import os
@@ -740,8 +739,7 @@ async def test_merge_duplicate_keys(merge_log_err, hass):
assert len(config["input_select"]) == 1
@asyncio.coroutine
def test_merge_customize(hass):
async def test_merge_customize(hass):
"""Test loading core config onto hass object."""
core_config = {
"latitude": 60,
@@ -755,7 +753,7 @@ def test_merge_customize(hass):
"pkg1": {"homeassistant": {"customize": {"b.b": {"friendly_name": "BB"}}}}
},
}
yield from config_util.async_process_ha_core_config(hass, core_config)
await config_util.async_process_ha_core_config(hass, core_config)
assert hass.data[config_util.DATA_CUSTOMIZE].get("b.b") == {"friendly_name": "BB"}