mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2026-09-13 18:46:17 +05:00
Some checks failed
CI / Linters (push) Waiting to run
CI / Complete test suite (push) Waiting to run
CI / Sharded and plugin tests (push) Waiting to run
CI / Documentation and root tests (push) Waiting to run
CI / CodeQL (push) Waiting to run
CI / Tested Python artifacts (push) Waiting to run
CI / Tested Docker images (push) Waiting to run
CI / All required CI lanes (push) Blocked by required conditions
Deploy Publicsite to GitHub Pages / deploy (push) Has been cancelled
24 lines
777 B
Python
24 lines
777 B
Python
import tempfile
|
|
from importlib.metadata import version
|
|
from pathlib import Path
|
|
|
|
from archivebox.tests.conftest import run_archivebox_cmd
|
|
|
|
|
|
def test_oneshot_runs_abx_dl_through_abxpkg_env_projection():
|
|
with tempfile.TemporaryDirectory(prefix="archivebox-oneshot-") as tmp_dir:
|
|
work_dir = Path(tmp_dir)
|
|
lib_dir = work_dir / "lib"
|
|
|
|
result = run_archivebox_cmd(
|
|
["oneshot", "--version"],
|
|
cwd=work_dir,
|
|
env={"ABXPKG_LIB_DIR": str(lib_dir)},
|
|
)
|
|
|
|
abx_dl_projection = lib_dir / "env" / "bin" / "abx-dl"
|
|
assert result.returncode == 0, result.stderr
|
|
assert version("abx-dl") in result.stdout
|
|
assert abx_dl_projection.is_symlink()
|
|
assert abx_dl_projection.resolve().is_file()
|