2020-07-07 13:36:58 +00:00
|
|
|
import os
|
|
|
|
import subprocess
|
|
|
|
|
|
|
|
import pytest
|
|
|
|
|
|
|
|
@pytest.fixture
|
|
|
|
def process(tmp_path):
|
|
|
|
os.chdir(tmp_path)
|
|
|
|
process = subprocess.run(['archivebox', 'init'], capture_output=True)
|
2020-08-04 13:42:30 +00:00
|
|
|
return process
|
|
|
|
|
|
|
|
@pytest.fixture
|
|
|
|
def disable_extractors_dict():
|
|
|
|
env = os.environ.copy()
|
|
|
|
env.update({
|
|
|
|
"USE_WGET": "false",
|
|
|
|
"USE_SINGLEFILE": "false",
|
2020-08-11 13:58:49 +00:00
|
|
|
"USE_READABILITY": "false",
|
2020-09-22 08:47:43 +00:00
|
|
|
"USE_MERCURY": "false",
|
2023-10-24 01:42:25 +00:00
|
|
|
"SAVE_HTMLTOTEXT": "false",
|
2020-08-04 13:42:30 +00:00
|
|
|
"SAVE_PDF": "false",
|
|
|
|
"SAVE_SCREENSHOT": "false",
|
|
|
|
"SAVE_DOM": "false",
|
2020-09-24 13:37:27 +00:00
|
|
|
"SAVE_HEADERS": "false",
|
2020-08-04 13:42:30 +00:00
|
|
|
"USE_GIT": "false",
|
|
|
|
"SAVE_MEDIA": "false",
|
|
|
|
"SAVE_ARCHIVE_DOT_ORG": "false"
|
|
|
|
})
|
2020-10-27 14:11:41 +00:00
|
|
|
return env
|