mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2026-09-14 11:06:13 +05:00
Install managed Chrome in browser-dependent CI tests
This commit is contained in:
parent
c5d11c3224
commit
5b6288c96a
2
.github/workflows/test-parallel.yml
vendored
2
.github/workflows/test-parallel.yml
vendored
@ -84,7 +84,6 @@ jobs:
|
||||
needs: discover-tests
|
||||
env:
|
||||
PYTHONPATH: ${{ github.workspace }}/abxpkg:${{ github.workspace }}/abx-plugins:${{ github.workspace }}/abx-dl
|
||||
CHROME_BINARY: /usr/bin/chromium
|
||||
CHROME_HEADLESS: "true"
|
||||
CHROME_SANDBOX: "false"
|
||||
PERSONAS_DIR: /tmp/abx-personas
|
||||
@ -156,7 +155,6 @@ jobs:
|
||||
needs: discover-tests
|
||||
env:
|
||||
PYTHONPATH: ${{ github.workspace }}/abxpkg:${{ github.workspace }}/abx-plugins:${{ github.workspace }}/abx-dl
|
||||
CHROME_BINARY: /usr/bin/chromium
|
||||
CHROME_HEADLESS: "true"
|
||||
CHROME_SANDBOX: "false"
|
||||
PERSONAS_DIR: /tmp/abx-personas
|
||||
|
||||
@ -71,7 +71,7 @@ def test_cli_add_real_urls_with_options_writes_inspectable_outputs(tmp_path, pro
|
||||
"CHROME_SANDBOX": "false",
|
||||
}
|
||||
install_result = subprocess.run(
|
||||
[sys.executable, "-m", "archivebox", "install", "puppeteer"],
|
||||
[sys.executable, "-m", "archivebox", "install", "chrome"],
|
||||
cwd=tmp_path,
|
||||
capture_output=True,
|
||||
text=True,
|
||||
|
||||
@ -8,9 +8,9 @@ from .fixtures import disable_extractors_dict, process
|
||||
FIXTURES = (disable_extractors_dict, process)
|
||||
|
||||
|
||||
def _install_puppeteer(tmp_path, env):
|
||||
def _install_chrome(tmp_path, env):
|
||||
install_process = subprocess.run(
|
||||
[sys.executable, "-m", "archivebox", "install", "puppeteer"],
|
||||
[sys.executable, "-m", "archivebox", "install", "chrome"],
|
||||
cwd=tmp_path,
|
||||
capture_output=True,
|
||||
text=True,
|
||||
@ -23,7 +23,7 @@ def _install_puppeteer(tmp_path, env):
|
||||
def test_title_is_extracted(tmp_path, process, disable_extractors_dict):
|
||||
"""Test that title is extracted from the page."""
|
||||
disable_extractors_dict.update({"SAVE_TITLE": "true"})
|
||||
_install_puppeteer(tmp_path, disable_extractors_dict)
|
||||
_install_chrome(tmp_path, disable_extractors_dict)
|
||||
add_process = subprocess.run(
|
||||
["archivebox", "add", "--plugins=wget,title", "https://example.com"],
|
||||
capture_output=True,
|
||||
@ -51,7 +51,7 @@ def test_title_is_htmlencoded_in_index_html(tmp_path, process, disable_extractor
|
||||
and breaks the layout.
|
||||
"""
|
||||
disable_extractors_dict.update({"SAVE_TITLE": "true"})
|
||||
_install_puppeteer(tmp_path, disable_extractors_dict)
|
||||
_install_chrome(tmp_path, disable_extractors_dict)
|
||||
add_process = subprocess.run(
|
||||
["archivebox", "add", "--plugins=wget,title", "https://example.com"],
|
||||
capture_output=True,
|
||||
|
||||
@ -80,8 +80,8 @@ dependencies = [
|
||||
### Binary/Package Management
|
||||
"abxbus>=2.5.4", # EventBus API
|
||||
"abxpkg>=1.10.7", # for: detecting, versioning, and installing binaries via apt/brew/pip/npm
|
||||
"abx-plugins>=1.10.63", # shared ArchiveBox plugin package with Chrome/Puppeteer dependency wiring
|
||||
"abx-dl>=1.10.63", # shared ArchiveBox downloader package with blocking install preflight
|
||||
"abx-plugins>=1.10.65", # shared ArchiveBox plugin package with Chrome/Puppeteer dependency wiring
|
||||
"abx-dl>=1.10.65", # shared ArchiveBox downloader package with blocking install preflight
|
||||
### UUID7 backport for Python <3.14
|
||||
"uuid7>=0.1.0; python_version < '3.14'", # provides the uuid_extensions module on Python 3.13
|
||||
]
|
||||
|
||||
Loading…
Reference in New Issue
Block a user