Custom component loading cleanup (#14211)

* Clean up custom component loading

* Fix some tests

* Fix some stuff

* Make imports work again

* Fix tests

* Remove debug print

* Lint
This commit is contained in:
Paulus Schoutsen 2018-05-01 14:57:30 -04:00 committed by Pascal Vizeli
parent 5d96751168
commit 83d300fd11
50 changed files with 315 additions and 392 deletions

View file

@ -10,8 +10,6 @@ import voluptuous as vol
import homeassistant.helpers.config_validation as cv
from tests.common import get_test_home_assistant
def test_boolean():
"""Test boolean validation."""
@ -256,24 +254,6 @@ def test_event_schema():
cv.EVENT_SCHEMA(value)
def test_platform_validator():
"""Test platform validation."""
hass = None
try:
hass = get_test_home_assistant()
schema = vol.Schema(cv.platform_validator('light'))
with pytest.raises(vol.MultipleInvalid):
schema('platform_that_does_not_exist')
schema('hue')
finally:
if hass is not None:
hass.stop()
def test_icon():
"""Test icon validation."""
schema = vol.Schema(cv.icon)