Changeset View
Changeset View
Standalone View
Standalone View
swh/deposit/tests/conftest.py
Show First 20 Lines • Show All 124 Lines • ▼ Show 20 Lines | def requests_mock_datadir(datadir, requests_mock_datadir): | ||||
requests_mock_datadir.put(re.compile("https://"), body=cb) | requests_mock_datadir.put(re.compile("https://"), body=cb) | ||||
requests_mock_datadir.post(re.compile("https://"), body=cb) | requests_mock_datadir.post(re.compile("https://"), body=cb) | ||||
return requests_mock_datadir | return requests_mock_datadir | ||||
@pytest.fixture | @pytest.fixture | ||||
def common_deposit_config(swh_scheduler_config, swh_storage_backend_config): | def common_deposit_config(swh_scheduler_config, swh_storage_backend_config): | ||||
return { | return { | ||||
"max_upload_size": 500, | "max_upload_size": 5000, | ||||
"extraction_dir": "/tmp/swh-deposit/test/extraction-dir", | "extraction_dir": "/tmp/swh-deposit/test/extraction-dir", | ||||
"checks": False, | "checks": False, | ||||
"scheduler": {"cls": "local", **swh_scheduler_config,}, | "scheduler": {"cls": "local", **swh_scheduler_config,}, | ||||
"storage": swh_storage_backend_config, | "storage": swh_storage_backend_config, | ||||
"storage_metadata": swh_storage_backend_config, | "storage_metadata": swh_storage_backend_config, | ||||
"swh_authority_url": "http://deposit.softwareheritage.example/", | "swh_authority_url": "http://deposit.softwareheritage.example/", | ||||
} | } | ||||
▲ Show 20 Lines • Show All 470 Lines • Show Last 20 Lines |