test/quadlet: check that service ran successfully

Services generated from a volume quadlet no longer have
RemainAfterExit=yes by default[1], so the is_service_active check will
fail with new versions of podman. Instead we can check that it ran
successfully.

[1] https://github.com/podman-container-tools/podman/pull/29375
This commit is contained in:
Angel Cervera Roldan 2026-10-27 14:11:32 +00:00 committed by Angel Cervera Roldan
parent 952c859171
commit bcc41110a5

View file

@ -10,8 +10,8 @@ set -xeuo pipefail
. "$KOLA_EXT_DATA/commonlib.sh"
# Test volume
if ! is_service_active test-volume.service; then
fatal "test-volume.service failed to start"
if [[ $(systemctl show test-volume.service --property=Result --value) != "success" ]]; then
fatal "test-volume.service did not start successfully"
fi
volume_info=$(podman volume inspect systemd-test)
if [[ "$(jq -r '.[0].Labels."org.test.Key"' <<< "$volume_info")" != "quadlet-test-volume" ]]; then