Module: check_mk
Branch: master
Commit: e670af63fa00349c620b42286a4611b95464d2ed
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=e670af63fa0034…
Author: Sven Panne <sp(a)mathias-kettner.de>
Date: Wed May 9 11:43:32 2018 +0200
Synched test with latest EC changes.
Change-Id: I085d607bba5e99def4360837de926be9cc1ddca8
---
tests/integration/cmk/ec/test_mkeventd_status.py | 26 ++++++++++++++++--------
1 file changed, 18 insertions(+), 8 deletions(-)
diff --git a/tests/integration/cmk/ec/test_mkeventd_status.py
b/tests/integration/cmk/ec/test_mkeventd_status.py
index aa709bb..e472e26 100644
--- a/tests/integration/cmk/ec/test_mkeventd_status.py
+++ b/tests/integration/cmk/ec/test_mkeventd_status.py
@@ -51,8 +51,13 @@ def slave_status():
@pytest.fixture(scope="function")
-def config(settings, slave_status):
- return cmk.ec.main.load_configuration(settings, slave_status)
+def mongodb():
+ return cmk.ec.main.MongoDB()
+
+
+(a)pytest.fixture(scope="function")
+def config(settings, slave_status, mongodb):
+ return cmk.ec.main.load_configuration(settings, slave_status, mongodb)
@pytest.fixture(scope="function")
@@ -61,8 +66,13 @@ def perfcounters():
@pytest.fixture(scope="function")
-def event_status(settings, config, perfcounters):
- return cmk.ec.main.EventStatus(settings, config, perfcounters)
+def active_history_period():
+ return cmk.ec.main.ActiveHistoryPeriod()
+
+
+(a)pytest.fixture(scope="function")
+def event_status(settings, config, perfcounters, mongodb, active_history_period):
+ return cmk.ec.main.EventStatus(settings, config, perfcounters, mongodb,
active_history_period)
@pytest.fixture(scope="function")
@@ -71,13 +81,13 @@ def table_events(event_status):
@pytest.fixture(scope="function")
-def event_server(settings, config, slave_status, perfcounters, event_status,
table_events):
- return cmk.ec.main.EventServer(settings, config, slave_status, perfcounters,
event_status, table_events)
+def event_server(settings, config, slave_status, perfcounters, mongodb,
active_history_period, event_status, table_events):
+ return cmk.ec.main.EventServer(settings, config, slave_status, perfcounters, mongodb,
active_history_period, event_status, table_events)
@pytest.fixture(scope="function")
-def status_server(settings, config, slave_status, perfcounters, event_status,
event_server, table_events):
- return cmk.ec.main.StatusServer(settings, config, slave_status, perfcounters,
event_status, event_server, table_events, threading.Event())
+def status_server(settings, config, slave_status, perfcounters, mongodb,
active_history_period, event_status, event_server, table_events):
+ return cmk.ec.main.StatusServer(settings, config, slave_status, perfcounters,
mongodb, active_history_period, event_status, event_server, table_events,
threading.Event())
def test_handle_client(status_server):