From 0ab91ef27dcd5a689f8cc887d21c848deeb71b39 Mon Sep 17 00:00:00 2001 From: VakarisZ Date: Thu, 20 May 2021 10:22:20 +0300 Subject: [PATCH] Altered mongomock fixture to be a module-scoped, in an attempt to fix fixture import error --- monkey/tests/unit_tests/monkey_island/cc/mongomock_fixtures.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/monkey/tests/unit_tests/monkey_island/cc/mongomock_fixtures.py b/monkey/tests/unit_tests/monkey_island/cc/mongomock_fixtures.py index 079c91fb76f..26a41685a41 100644 --- a/monkey/tests/unit_tests/monkey_island/cc/mongomock_fixtures.py +++ b/monkey/tests/unit_tests/monkey_island/cc/mongomock_fixtures.py @@ -6,7 +6,7 @@ from monkey_island.cc.models.zero_trust.finding import Finding -@pytest.fixture(scope="session", autouse=True) +@pytest.fixture(scope="module", autouse=True) def change_to_mongo_mock(): # Make sure tests are working with mongomock mongoengine.disconnect()