]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
test: shortcut skip if both TEST_NO_QEMU and TEST_NO_NSPAWN are set
authorLuca Boccassi <bluca@debian.org>
Tue, 22 Dec 2020 17:51:40 +0000 (17:51 +0000)
committerLuca Boccassi <bluca@debian.org>
Fri, 1 Jan 2021 21:33:16 +0000 (21:33 +0000)
Allows to run all tests in bulk with TEST_NO_QEMU, skipping those where it is
mandatory, without wasting time building the image.

test/test-functions

index 1359156b17a2c7e387d973c183ddf42577429131..52331d78456b64e62c2f008199b433a860d6fec4 100644 (file)
@@ -2107,6 +2107,11 @@ do_test() {
         exit 0
     fi
 
+    if [ -n "$TEST_NO_QEMU" ] && [ -n "$TEST_NO_NSPAWN" ]; then
+        echo "TEST: $TEST_DESCRIPTION [SKIPPED]: both QEMU and nspawn disabled" >&2
+        exit 0
+    fi
+
     # Detect lib paths
     [[ $libdir ]] || for libdir in /lib64 /lib; do
         [[ -d $libdir ]] && libdirs+=" $libdir" && break