From: Karel Zak Date: Tue, 25 Jan 2011 15:36:28 +0000 (+0100) Subject: tests: skip non-compiled libmount tests X-Git-Tag: v2.19-rc3~2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6c2bbad199458562488fc249c10a6fa371d476f6;p=thirdparty%2Futil-linux.git tests: skip non-compiled libmount tests Signed-off-by: Karel Zak --- diff --git a/tests/ts/libmount/context b/tests/ts/libmount/context index 536ab1b507..4248f31327 100755 --- a/tests/ts/libmount/context +++ b/tests/ts/libmount/context @@ -14,6 +14,8 @@ LABEL=libmount-test UUID=$(uuidgen) MOUNTPOINT="$TS_MOUNTPOINT" +[ -x $TESTPROG ] || ts_skip "test not compiled" + modprobe --dry-run --quiet scsi_debug [ "$?" == 0 ] || ts_skip "missing scsi_debug module" diff --git a/tests/ts/libmount/context-utab b/tests/ts/libmount/context-utab index db039d1f15..5f36d28aa2 100755 --- a/tests/ts/libmount/context-utab +++ b/tests/ts/libmount/context-utab @@ -14,6 +14,8 @@ LABEL=libmount-test UUID=$(uuidgen) MOUNTPOINT="$TS_MOUNTPOINT" +[ -x $TESTPROG ] || ts_skip "test not compiled" + modprobe --dry-run --quiet scsi_debug [ "$?" == 0 ] || ts_skip "missing scsi_debug module" diff --git a/tests/ts/libmount/lock b/tests/ts/libmount/lock index 1230e5cc52..a6a0a60d58 100755 --- a/tests/ts/libmount/lock +++ b/tests/ts/libmount/lock @@ -10,6 +10,8 @@ ts_init "$*" TESTPROG="$TS_HELPER_LIBMOUNT_LOCK" +[ -x $TESTPROG ] || ts_skip "test not compiled" + # # Be careful with number of processes. Don't forget that there is time limit # when the mount waits on the mtab lock. If you define too much processes some diff --git a/tests/ts/libmount/optstr b/tests/ts/libmount/optstr index a58eaaa709..447c7e0ad6 100755 --- a/tests/ts/libmount/optstr +++ b/tests/ts/libmount/optstr @@ -10,6 +10,8 @@ ts_init "$*" TESTPROG="$TS_HELPER_LIBMOUNT_OPTSTR" +[ -x $TESTPROG ] || ts_skip "test not compiled" + ts_init_subtest "append" $TESTPROG --append "aaa,bbb=BBB,context=\"foo,bar,gogo\",ccc" "ddd" &> $TS_OUTPUT ts_finalize_subtest diff --git a/tests/ts/libmount/tabfiles b/tests/ts/libmount/tabfiles index 2de86807cb..cf3fb5cdb7 100755 --- a/tests/ts/libmount/tabfiles +++ b/tests/ts/libmount/tabfiles @@ -10,6 +10,8 @@ ts_init "$*" TESTPROG="$TS_HELPER_LIBMOUNT_TAB" +[ -x $TESTPROG ] || ts_skip "test not compiled" + ts_init_subtest "parse-fstab" $TESTPROG --parse "$TS_SELF/files/fstab" &> $TS_OUTPUT sed -i -e 's/fs: 0x.*/fs:/g' $TS_OUTPUT diff --git a/tests/ts/libmount/tabfiles-tags b/tests/ts/libmount/tabfiles-tags index da76724bb6..893c65bc8a 100755 --- a/tests/ts/libmount/tabfiles-tags +++ b/tests/ts/libmount/tabfiles-tags @@ -9,6 +9,8 @@ ts_skip_nonroot TESTPROG="$TS_HELPER_LIBMOUNT_TAB" +[ -x $TESTPROG ] || ts_skip "test not compiled" + # # Init device # diff --git a/tests/ts/libmount/update b/tests/ts/libmount/update index 65e0ea5277..bbe19ffd35 100755 --- a/tests/ts/libmount/update +++ b/tests/ts/libmount/update @@ -10,6 +10,8 @@ ts_init "$*" TESTPROG="$TS_HELPER_LIBMOUNT_UPDATE" +[ -x $TESTPROG ] || ts_skip "test not compiled" + # IMPORTANT notes: # # - the $TS_OUTPUT variable is between ts_init_subtest and ts_finalize_subtest diff --git a/tests/ts/libmount/utils b/tests/ts/libmount/utils index e06c9b9cd3..fbd63593b8 100755 --- a/tests/ts/libmount/utils +++ b/tests/ts/libmount/utils @@ -10,6 +10,8 @@ ts_init "$*" TESTPROG="$TS_HELPER_LIBMOUNT_UTILS" +[ -x $TESTPROG ] || ts_skip "test not compiled" + ts_init_subtest "match-fstype" $TESTPROG --match-fstype ext3 "ext2,ext3,cifs" &> $TS_OUTPUT ts_finalize_subtest