From: Henrik Gombos Date: Wed, 17 May 2023 00:46:19 +0000 (+0000) Subject: test: move test condition to test_check X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1843c16cafff005f798c379225e97dce459bc3dd;p=thirdparty%2Fdracut.git test: move test condition to test_check This enables skipping the test instead of failing it. --- diff --git a/test/TEST-30-ISCSI/test.sh b/test/TEST-30-ISCSI/test.sh index b540fe039..a6aa17330 100755 --- a/test/TEST-30-ISCSI/test.sh +++ b/test/TEST-30-ISCSI/test.sh @@ -125,12 +125,14 @@ test_run() { return $ret } -test_setup() { +test_check() { if ! command -v tgtd &> /dev/null || ! command -v tgtadm &> /dev/null; then echo "Need tgtd and tgtadm from scsi-target-utils" return 1 fi +} +test_setup() { kernel=$KVERSION # Create what will eventually be our root filesystem onto an overlay rm -rf -- "$TESTDIR"/overlay diff --git a/test/TEST-35-ISCSI-MULTI/test.sh b/test/TEST-35-ISCSI-MULTI/test.sh index 8979f59a9..19ee07557 100755 --- a/test/TEST-35-ISCSI-MULTI/test.sh +++ b/test/TEST-35-ISCSI-MULTI/test.sh @@ -137,12 +137,14 @@ test_run() { return $ret } -test_setup() { +test_check() { if ! command -v tgtd &> /dev/null || ! command -v tgtadm &> /dev/null; then echo "Need tgtd and tgtadm from scsi-target-utils" return 1 fi +} +test_setup() { kernel=$KVERSION # Create what will eventually be our root filesystem onto an overlay rm -rf -- "$TESTDIR"/overlay