forked from p15670423/monkey
Add fixture for fake db dir in test_process_runner.py
This commit is contained in:
parent
58745a0eb4
commit
0be8e56858
|
@ -7,9 +7,13 @@ from monkey_island.cc.setup.mongo_process_runner import MongoDbRunner
|
|||
TEST_DIR_NAME = "test_dir"
|
||||
|
||||
|
||||
@pytest.fixture(autouse=True)
|
||||
def fake_db_dir(monkeypatch, tmpdir):
|
||||
monkeypatch.setattr("monkey_island.cc.setup.mongo_process_runner.DB_DIR_NAME", TEST_DIR_NAME)
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def expected_path(monkeypatch, tmpdir):
|
||||
monkeypatch.setattr("monkey_island.cc.setup.mongo_process_runner.DB_DIR_NAME", TEST_DIR_NAME)
|
||||
expected_path = os.path.join(tmpdir, TEST_DIR_NAME)
|
||||
return expected_path
|
||||
|
||||
|
|
|
@ -166,6 +166,8 @@ IBM # unused variable (monkey/common/cloud/environment_names.py:11)
|
|||
DigitalOcean # unused variable (monkey/common/cloud/environment_names.py:12)
|
||||
_.aws_info # unused attribute (monkey/monkey_island/cc/environment/aws.py:13)
|
||||
build_from_config_file_contents # unused method 'build_from_config_file_contents' (\monkey_island\setup\island_config_options.py:18)
|
||||
fake_db_dir # unused function 'fake_db_dir' (monkey/tests/unit_tests/monkey_island/cc/setup/test_process_runner.py:10)
|
||||
|
||||
|
||||
# these are not needed for it to work, but may be useful extra information to understand what's going on
|
||||
WINDOWS_PBA_TYPE # unused variable (monkey/monkey_island/cc/resources/pba_file_upload.py:23)
|
||||
|
|
Loading…
Reference in New Issue