smoketest: 30 gets the older installers past GNOME's dialog and polkit
shellcheck / shellcheck (push) Failing after 18s

ca658dc installs extensions with plain gext install, which waits for a
GNOME Shell dialog no one clicks; add --filesystem, as HEAD does. ca658dc
and d8d93a4 run flatpak install as the user, which polkit refuses over
SSH; allow it for the install only, with a rule removed afterwards.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-06 09:04:18 -07:00
co-authored by Claude Opus 5.5
parent 8e18a6238b
commit 061121226d
@@ -13,18 +13,31 @@ scenario() {
sha="$(git -C "$SMOKETEST_REPO" rev-parse "$VARIANT^{commit}")"
upstream_set "$sha"
# Older installers ask for packages that no longer build. Install those
# baselines with a fix on top, then put the clone back at the baseline
# Older installers can't finish here as they did on a real machine. Install
# those baselines with fixes on top, then put the clone back at the baseline
# itself, as on a machine installed back then: update pulls --ff-only.
# The source-built herdr pins a zig version Arch has moved on from;
# herdr-bin provides herdr, and is what HEAD installs instead
if git -C "$SMOKETEST_REPO" show "$sha:packages.conf" | grep -qx '[[:space:]]*herdr'; then
upstream_commit "Smoketest: herdr-bin for herdr" '
sed -i "s/^\([[:space:]]*\)herdr$/\1herdr-bin/" packages.conf'
fi
# - The source-built herdr pins a zig version Arch has moved on from;
# herdr-bin provides herdr, and is what HEAD installs instead
# - Plain gext install asks GNOME Shell, which shows a dialog no one clicks;
# --filesystem doesn't ask, and is what HEAD does
upstream_commit "Smoketest: fixes to install this baseline in a VM" '
sed -i "s/^\([[:space:]]*\)herdr$/\1herdr-bin/" packages.conf
sed -i "s|gext install|gext --filesystem install|" gnome/gnome-extensions.sh
git diff --quiet && exit 0'
# Older installers also run flatpak install as the user, which polkit allows
# at the desktop (or asks there) but refuses over SSH. HEAD uses sudo
run_in_vm allow-flatpak "printf '%s\n' \
'polkit.addRule(function(action, subject) {' \
' if (action.id.indexOf(\"org.freedesktop.Flatpak.\") == 0 && subject.user == \"'\"\$USER\"'\")' \
' return polkit.Result.YES;' \
'});' | sudo tee /etc/polkit-1/rules.d/00-smoketest-flatpak.rules"
assert_status 0
cd_install
assert_status 0
run_in_vm reset "git -C ~/.local/share/coredesktop reset -q --hard $(q "$sha")"
run_in_vm reset "sudo rm /etc/polkit-1/rules.d/00-smoketest-flatpak.rules
git -C ~/.local/share/coredesktop reset -q --hard $(q "$sha")"
assert_status 0
vm_reboot