mirror of
https://github.com/home-assistant/core.git
synced 2025-07-16 17:57:11 +00:00
properly cleanup after config test
This commit is contained in:
parent
ffccca1f60
commit
659d67f362
@ -22,6 +22,7 @@ from tests.common import (
|
|||||||
|
|
||||||
CONFIG_DIR = get_test_config_dir()
|
CONFIG_DIR = get_test_config_dir()
|
||||||
YAML_PATH = os.path.join(CONFIG_DIR, config_util.YAML_CONFIG_FILE)
|
YAML_PATH = os.path.join(CONFIG_DIR, config_util.YAML_CONFIG_FILE)
|
||||||
|
VERSION_PATH = os.path.join(CONFIG_DIR, config_util.VERSION_FILE)
|
||||||
ORIG_TIMEZONE = dt_util.DEFAULT_TIME_ZONE
|
ORIG_TIMEZONE = dt_util.DEFAULT_TIME_ZONE
|
||||||
|
|
||||||
|
|
||||||
@ -41,6 +42,9 @@ class TestConfig(unittest.TestCase):
|
|||||||
if os.path.isfile(YAML_PATH):
|
if os.path.isfile(YAML_PATH):
|
||||||
os.remove(YAML_PATH)
|
os.remove(YAML_PATH)
|
||||||
|
|
||||||
|
if os.path.isfile(VERSION_PATH):
|
||||||
|
os.remove(VERSION_PATH)
|
||||||
|
|
||||||
if hasattr(self, 'hass'):
|
if hasattr(self, 'hass'):
|
||||||
self.hass.stop()
|
self.hass.stop()
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user