Check config before restarting (#5609)

* Check config before restarting.

* Make check_config on restart async

* don't check if notification service exists

* Use .communicate()

* Reduce the number of notifications. Add tests.
This commit is contained in:
andrey-git authored and Paulus Schoutsen committed 2017-02-07 01:19:08 -08:00
1 parent 51810620fb
commit f774538e66
4 files changed
+73 -5

No files matched your search

+5
View File
@@ -388,6 +388,11 @@ def mock_coro(return_value=None):
return coro
def mock_generator(return_value=None):
"""Helper method to return a coro generator that returns a value."""
return mock_coro(return_value)()
@contextmanager
def assert_setup_component(count, domain=None):
"""Collect valid configuration from setup_component.