You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by ad...@apache.org on 2018/03/26 07:58:38 UTC
[ambari] 01/03: AMBARI-23197. Ambari Agent unit test failure on
Ubuntu
This is an automated email from the ASF dual-hosted git repository.
adoroszlai pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ambari.git
commit 9455ae097236c306c28c46f3c426c2893051962f
Author: Doroszlai, Attila <ad...@apache.org>
AuthorDate: Sun Mar 25 11:10:39 2018 +0200
AMBARI-23197. Ambari Agent unit test failure on Ubuntu
---
.../src/test/python/ambari_agent/TestAlertSchedulerHandler.py | 10 ++--------
1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/ambari-agent/src/test/python/ambari_agent/TestAlertSchedulerHandler.py b/ambari-agent/src/test/python/ambari_agent/TestAlertSchedulerHandler.py
index fb20a8b..7647070 100644
--- a/ambari-agent/src/test/python/ambari_agent/TestAlertSchedulerHandler.py
+++ b/ambari-agent/src/test/python/ambari_agent/TestAlertSchedulerHandler.py
@@ -41,13 +41,6 @@ class TestAlertSchedulerHandler(TestCase):
def setUp(self):
self.config = AmbariConfig()
- def test_load_definitions(self):
- scheduler = AlertSchedulerHandler(TEST_PATH, TEST_PATH, TEST_PATH, TEST_PATH, TEST_PATH, None)
-
- definitions = scheduler._AlertSchedulerHandler__load_definitions()
-
- self.assertEquals(len(definitions), 1)
-
@patch("ambari_commons.network.reconfigure_urllib2_opener")
def test_job_context_injector(self, reconfigure_urllib2_opener_mock):
self.config.use_system_proxy_setting = lambda: False
@@ -302,7 +295,8 @@ class TestAlertSchedulerHandler(TestCase):
def test_load_definitions_noFile(self):
initializer_module = InitializerModule()
initializer_module.init()
-
+ initializer_module.alert_definitions_cache.rewrite_cluster_cache('0', {'alertDefinitions':[]})
+
scheduler = AlertSchedulerHandler(initializer_module)
#('wrong_path', 'wrong_path', 'wrong_path', 'wrong_path', 'wrong_path', None, self.config, None)
scheduler._AlertSchedulerHandler__config_maps = {
--
To stop receiving notification emails like this one, please contact
adoroszlai@apache.org.