diff --git a/.github/workflows/release-please.yml b/.github/workflows/release-please.yml index 6ffc9c7..7b32a2d 100644 --- a/.github/workflows/release-please.yml +++ b/.github/workflows/release-please.yml @@ -90,7 +90,14 @@ jobs: sed -i "s/^pkgver=.*/pkgver=${TAG#v}/" PKGBUILD grep -q "^pkgver=${TAG#v}$" PKGBUILD useradd -m build && chown -R build:build . - su build -c 'makepkg -f --nodeps --noconfirm' + # --nocheck, unlike the other repos' copies of this job: this + # PKGBUILD's check() runs bin/aikit-selftest, which needs tmux, sqlite, + # gh and a real session. In a build container 40 of its 61 checks fail + # for want of an environment, not for want of correctness. The selftest + # is not skipped -- it is a job of its own in ci.yml, and it has to be + # green before anything reaches main. Running it twice, the second time + # somewhere it cannot work, only ever produces a false red. + su build -c 'makepkg -f --nodeps --nocheck --noconfirm' ls -l ./*.pkg.tar.* - name: Attach it to the release diff --git a/tests/test_pkgbuild.sh b/tests/test_pkgbuild.sh index 1e47db1..b1e02df 100755 --- a/tests/test_pkgbuild.sh +++ b/tests/test_pkgbuild.sh @@ -35,6 +35,12 @@ check "and the rewrite is verified" grep -q 'grep -q "\^pkgver=\${TAG#v}\$ check "extra-files is not used" bash -c '! grep -q "extra-files" release-please-config.json' check "the upload globs" grep -q '\*.pkg.tar.\*' "$WF" check "gh is installed in the container" grep -q 'github-cli' "$WF" +# check() runs the selftest, which needs tmux/sqlite/gh and a session; in a build +# container it fails for want of an environment. ci.yml runs it properly and has +# to be green before main -- running it twice, the second time somewhere it +# cannot work, only ever produces a false red. +check "the build skips check() in CI" grep -q -- '--nocheck' "$WF" +check "but the selftest is still a gate" grep -q 'aikit-selftest' .github/workflows/ci.yml (( fails == 0 )) && echo "all ok" || echo "$fails failed" exit $(( fails > 0 ))