Fix unit tests

This commit is contained in:
Patrick Robertson
2025-01-30 16:46:53 +01:00
parent d6b4b7a932
commit d76063c3f3
2 changed files with 3 additions and 3 deletions

View File

@@ -28,7 +28,7 @@ def setup_module(request):
# add the tmp_dir to the module
tmp_dir = TemporaryDirectory()
m.tmp_dir = tmp_dir
m.tmp_dir = tmp_dir.name
def cleanup():
_LAZY_LOADED_MODULES.pop(module_name)

View File

@@ -66,7 +66,7 @@ def test_load_module(example_module):
# check that the vlaue is set on the module itself
assert loaded_module.csv_file == "db.csv"
@pytest.mark.parametrize("module_name", ["cli_feeder", "local_storage", "generic_extractor", "html_formatter", "csv_db"])
@pytest.mark.parametrize("module_name", ["local_storage", "generic_extractor", "html_formatter", "csv_db"])
def test_load_modules(module_name):
# test that specific modules can be loaded
module = get_module_lazy(module_name)
@@ -84,7 +84,7 @@ def test_load_modules(module_name):
assert loaded_module.name in loaded_module.config.keys()
@pytest.mark.parametrize("module_name", ["cli_feeder", "local_storage", "generic_extractor", "html_formatter", "csv_db"])
@pytest.mark.parametrize("module_name", ["local_storage", "generic_extractor", "html_formatter", "csv_db"])
def test_lazy_base_module(module_name):
lazy_module = get_module_lazy(module_name)