summaryrefslogtreecommitdiffstats
path: root/test/units
diff options
context:
space:
mode:
authorRichard Maw <richard.maw@codethink.co.uk>2024-04-05 18:38:18 +0200
committerDaan De Meyer <daan.j.demeyer@gmail.com>2024-05-06 10:56:55 +0200
commit7afb53371127602af3ea62cde2ce9c24d51cd363 (patch)
treec565b9d499943ca894b4bb1403b2a70452fb9364 /test/units
parenttest: Fix udev storage test name (diff)
downloadsystemd-7afb53371127602af3ea62cde2ce9c24d51cd363.tar.xz
systemd-7afb53371127602af3ea62cde2ce9c24d51cd363.zip
TEST-21-DFUZZER: Skip test if dfuzzer is not installed
Diffstat (limited to 'test/units')
-rwxr-xr-xtest/units/testsuite-21.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/units/testsuite-21.sh b/test/units/testsuite-21.sh
index 7b2013fb51..08ebfd91eb 100755
--- a/test/units/testsuite-21.sh
+++ b/test/units/testsuite-21.sh
@@ -3,6 +3,12 @@
set -eux
set -o pipefail
+# check dfuzzer is present before testing
+if ! command -v dfuzzer &>/dev/null; then
+ echo "dfuzzer is not installed, skipping" | tee --append /skipped
+ exit 77
+fi
+
# Save the end.service state before we start fuzzing, as it might get changed
# on the fly by one of the fuzzers
systemctl list-jobs | grep -F 'end.service' && SHUTDOWN_AT_EXIT=1 || SHUTDOWN_AT_EXIT=0