Add config endpoint for scene (#28429)

* Add config endpoint for scene

* Add scenes to default config

* Fix test and add context to websocket service call

* Update scene.py

* Add tests
This commit is contained in:
Bram Kragten authored and Paulus Schoutsen committed 2019-11-04 12:38:18 -08:00
1 parent bbe0cf3a0c
commit e419689229
7 files changed
+235 -4

No files matched your search

+4
View File
@@ -44,6 +44,7 @@ VERSION_PATH = os.path.join(CONFIG_DIR, config_util.VERSION_FILE)
GROUP_PATH = os.path.join(CONFIG_DIR, config_util.GROUP_CONFIG_PATH)
AUTOMATIONS_PATH = os.path.join(CONFIG_DIR, config_util.AUTOMATION_CONFIG_PATH)
SCRIPTS_PATH = os.path.join(CONFIG_DIR, config_util.SCRIPT_CONFIG_PATH)
SCENES_PATH = os.path.join(CONFIG_DIR, config_util.SCENE_CONFIG_PATH)
ORIG_TIMEZONE = dt_util.DEFAULT_TIME_ZONE
@@ -75,6 +76,9 @@ def teardown():
if os.path.isfile(SCRIPTS_PATH):
os.remove(SCRIPTS_PATH)
if os.path.isfile(SCENES_PATH):
os.remove(SCENES_PATH)
async def test_create_default_config(hass):
"""Test creation of default config."""