]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
tests: don't fail if QEMU is not available
authorMartin Pitt <martin.pitt@ubuntu.com>
Thu, 23 Jun 2016 08:23:29 +0000 (10:23 +0200)
committerMartin Pitt <martin.pitt@ubuntu.com>
Fri, 24 Jun 2016 09:28:35 +0000 (11:28 +0200)
Fix TEST-{08,09,10,11} to properly skip the test if QEMU is not available
instead of failing, like in the other tests.

test/TEST-08-ISSUE-2730/test.sh
test/TEST-09-ISSUE-2691/test.sh
test/TEST-10-ISSUE-2467/test.sh
test/TEST-11-ISSUE-3166/test.sh

index 409140157af1a7e3015f69c126b42c06ed959c36..e3b42a5254b00128f64956c30e5416bba1f837b8 100755 (executable)
@@ -23,8 +23,11 @@ check_result_qemu() {
 }
 
 test_run() {
-    run_qemu || return 1
-    check_result_qemu || return 1
+    if run_qemu; then
+        check_result_qemu || return 1
+    else
+        dwarn "can't run QEMU, skipping"
+    fi
     return 0
 }
 
index e247694f015fc68d221aa0851576142a6233e2a8..a782cad37d0c72c277ed25bee133ed8b78b804af 100755 (executable)
@@ -22,8 +22,11 @@ check_result_qemu() {
 }
 
 test_run() {
-    run_qemu || return 1
-    check_result_qemu || return 1
+    if run_qemu; then
+        check_result_qemu || return 1
+    else
+        dwarn "can't run QEMU, skipping"
+    fi
     return 0
 }
 
index a652b0d812af5b79d5e97da85bc3d331309efb9a..4eca6784bce24f07ff35302165bc21c669b3131f 100755 (executable)
@@ -21,8 +21,11 @@ check_result_qemu() {
 }
 
 test_run() {
-    run_qemu || return 1
-    check_result_qemu || return 1
+    if run_qemu; then
+        check_result_qemu || return 1
+    else
+        dwarn "can't run QEMU, skipping"
+    fi
     return 0
 }
 
index 7913537e9bcc899654672ffaf0d5bf9fc91cdeef..0f269c8211fd58dfa9a06f2cd6f604feafd1fab6 100755 (executable)
@@ -21,8 +21,11 @@ check_result_qemu() {
 }
 
 test_run() {
-    run_qemu || return 1
-    check_result_qemu || return 1
+    if run_qemu; then
+        check_result_qemu || return 1
+    else
+        dwarn "can't run QEMU, skipping"
+    fi
     return 0
 }