From 8a02305277037eec0b40132e837103373fd3dfb3 Mon Sep 17 00:00:00 2001 From: Mike Salvatore Date: Wed, 10 Aug 2022 12:46:58 -0400 Subject: [PATCH] Common: Export PyPubSubEventQueue from common.event_queue --- monkey/common/event_queue/__init__.py | 1 + monkey/monkey_island/cc/services/initialize.py | 3 +-- .../unit_tests/common/event_queue/test_pypubsub_event_queue.py | 3 +-- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/monkey/common/event_queue/__init__.py b/monkey/common/event_queue/__init__.py index 5d04040e2..f88abe300 100644 --- a/monkey/common/event_queue/__init__.py +++ b/monkey/common/event_queue/__init__.py @@ -1,2 +1,3 @@ from .types import EventSubscriber from .i_event_queue import IEventQueue +from .pypubsub_event_queue import PyPubSubEventQueue diff --git a/monkey/monkey_island/cc/services/initialize.py b/monkey/monkey_island/cc/services/initialize.py index 6247ea64d..fc7b6e432 100644 --- a/monkey/monkey_island/cc/services/initialize.py +++ b/monkey/monkey_island/cc/services/initialize.py @@ -14,8 +14,7 @@ from common.agent_configuration import ( ) from common.aws import AWSInstance from common.common_consts.telem_categories import TelemCategoryEnum -from common.event_queue import IEventQueue -from common.event_queue.pypubsub_event_queue import PyPubSubEventQueue +from common.event_queue import IEventQueue, PyPubSubEventQueue from common.utils.file_utils import get_binary_io_sha256_hash from common.version import get_version from monkey_island.cc import Version diff --git a/monkey/tests/unit_tests/common/event_queue/test_pypubsub_event_queue.py b/monkey/tests/unit_tests/common/event_queue/test_pypubsub_event_queue.py index b6edc4e46..deaa836f4 100644 --- a/monkey/tests/unit_tests/common/event_queue/test_pypubsub_event_queue.py +++ b/monkey/tests/unit_tests/common/event_queue/test_pypubsub_event_queue.py @@ -6,8 +6,7 @@ from uuid import UUID import pytest from pubsub.core import Publisher -from common.event_queue import EventSubscriber, IEventQueue -from common.event_queue.pypubsub_event_queue import PyPubSubEventQueue +from common.event_queue import EventSubscriber, IEventQueue, PyPubSubEventQueue from common.events import AbstractEvent EVENT_TAG_1 = "event tag 1"