Skip to content

Bulk asynchronous downloader for multiple file hosts

test: fix scrape_mapper tests

NTFSvolumecfdbefaf3709
diff --git a/tests/test_scrape_mapper.py b/tests/test_scrape_mapper.py
index d1ebdff54..370d9cebf 100644
--- a/tests/test_scrape_mapper.py
+++ b/tests/test_scrape_mapper.py
@@ -28,6 +28,7 @@ TEST_BASE_CRAWLER = next(iter(crawlers.GENERIC_CRAWLERS))
def test_generic_crawlers_that_match_supported_crawlers_should_not_be_created(
running_manager: Manager, link: str
) -> None:
+ _ = scrape_mapper.get_crawlers_mapping()
crawler = next(iter(create_crawlers([link], TEST_BASE_CRAWLER)))
with pytest.raises(ValueError) as exc_info:
scrape_mapper.register_crawler(scrape_mapper.existing_crawlers, crawler(running_manager), from_user="raise")
@@ -45,6 +46,7 @@ def test_generic_crawlers_that_match_supported_crawlers_should_not_be_created(
def test_generic_crawlers_that_do_no_match_supported_crawlers_should_be_created(
running_manager: Manager, link: str
) -> None:
+ _ = scrape_mapper.get_crawlers_mapping()
crawler = next(iter(create_crawlers([link], TEST_BASE_CRAWLER)))
existing_crawlers = scrape_mapper.existing_crawlers.copy()
crawlers_before = set(existing_crawlers.values())