test(void): guard the tag-built release path offline
- build-release.sh: POSIX-only checks (dash runs the release), a release form is exactly X.Y.Z or X.Y.Z-alpha|beta|rcN, and the install smoke refuses a package that has no smoke recipe. - Tests: names and tag gate (exact match, committed template must agree), key refusals before any container starts (fake podman records calls), the render script pins only the build tree, podman wiring (only the sign phase sees the key, and it has no network), the xbps ordering of pre-release spellings, the workflow gates, tmpfs key staging, and the publish set (sdist, packages, signatures, repodata, client key).
This commit is contained in:
@@ -20,7 +20,7 @@ REPO_ROOT = Path(__file__).resolve().parents[1]
|
||||
VOID_DIR = REPO_ROOT / "packaging" / "void"
|
||||
TEMPLATE = VOID_DIR / "srcpkgs" / "python3-pywhispercpp" / "template"
|
||||
PINS = VOID_DIR / "tool_checksums.txt"
|
||||
BUILD_SH = VOID_DIR / "build.sh"
|
||||
BUILD_SH = VOID_DIR / "build-release.sh"
|
||||
INSTALL_SH = REPO_ROOT / "install.sh"
|
||||
UV_LOCK = REPO_ROOT / "uv.lock"
|
||||
|
||||
@@ -235,9 +235,8 @@ def test_build_script_uses_podman_and_the_pinned_image() -> None:
|
||||
scrubbed = text.lower().replace("never docker", "")
|
||||
assert "docker" not in scrubbed, "never Docker"
|
||||
assert "tool_checksums.txt" in text, "the image digest comes from the pins file"
|
||||
# The container flow lives in mounted files, not an inline sh -c
|
||||
# string: single quotes inside sh -c silently regroup the command.
|
||||
for name in ("container-main.sh", "container-build.sh"):
|
||||
path = VOID_DIR / name
|
||||
assert path.is_file(), f"missing container script: {path}"
|
||||
assert name in text, f"{BUILD_SH.name} must mount {name}"
|
||||
# The container flow lives in a mounted file, not an inline sh -c string:
|
||||
# single quotes inside sh -c silently regroup the command.
|
||||
name = "container-release.sh"
|
||||
assert (VOID_DIR / name).is_file(), f"missing container script: {name}"
|
||||
assert name in text, f"{BUILD_SH.name} must mount {name}"
|
||||
|
||||
Reference in New Issue
Block a user