test/system: Fix 260-sdnotify being silently skipped

PODMAN_CMD is uninitialized until basic_setup() runs, causing
podman_runtime() to invoke an empty command and fall back to [null].

Call basic_setup() before the runtime check to ensure PODMAN_CMD is
populated before use.

Signed-off-by: Ricardo Branco <rbranco@suse.de>
This commit is contained in:
Ricardo Branco 2026-04-05 16:43:40 +02:00
parent 12c656234c
commit 2d5f5395c2
No known key found for this signature in database

View file

@ -17,14 +17,14 @@ function setup() {
# Skip if systemd is not running
systemctl list-units &>/dev/null || skip "systemd not available"
basic_setup
# sdnotify fails with runc 1.0.0-3-dev2 on Ubuntu. Let's just
# assume that we work only with crun, nothing else.
runtime=$(podman_runtime)
if [[ "$runtime" != "crun" ]]; then
skip "this test only works with crun, not $runtime"
fi
basic_setup
}
function teardown() {