From 4e8d20328a137f30325e8ed668c56498cd20ac91 Mon Sep 17 00:00:00 2001 From: Pascal Vizeli Date: Fri, 10 Feb 2017 17:51:08 +0100 Subject: [PATCH] Fix check_config script. (#5853) --- homeassistant/scripts/check_config.py | 1 + tests/test_bootstrap.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/homeassistant/scripts/check_config.py b/homeassistant/scripts/check_config.py index b1ecaaa57ba..154754c667a 100644 --- a/homeassistant/scripts/check_config.py +++ b/homeassistant/scripts/check_config.py @@ -33,6 +33,7 @@ MOCKS = { } SILENCE = ( 'homeassistant.bootstrap.clear_secret_cache', + 'homeassistant.bootstrap.async_register_signal_handling', 'homeassistant.core._LOGGER.info', 'homeassistant.loader._LOGGER.info', 'homeassistant.bootstrap._LOGGER.info', diff --git a/tests/test_bootstrap.py b/tests/test_bootstrap.py index b2c644a68b9..10f23346ca3 100644 --- a/tests/test_bootstrap.py +++ b/tests/test_bootstrap.py @@ -58,7 +58,7 @@ class TestBootstrap: autospec=True) @mock.patch('homeassistant.util.location.detect_location_info', autospec=True, return_value=None) - @mock.patch('homeassistant.helpers.signal.async_register_signal_handling') + @mock.patch('homeassistant.bootstrap.async_register_signal_handling') def test_from_config_file(self, mock_upgrade, mock_detect, mock_signal): """Test with configuration file.""" components = set(['browser', 'conversation', 'script']) @@ -290,7 +290,7 @@ class TestBootstrap: assert 'comp' not in self.hass.config.components @mock.patch('homeassistant.bootstrap.enable_logging') - @mock.patch('homeassistant.helpers.signal.async_register_signal_handling') + @mock.patch('homeassistant.bootstrap.async_register_signal_handling') def test_home_assistant_core_config_validation(self, log_mock, sig_mock): """Test if we pass in wrong information for HA conf.""" # Extensive HA conf validation testing is done in test_config.py