summaryrefslogtreecommitdiffstats
path: root/tests/ts
diff options
context:
space:
mode:
authorKarel Zak2014-05-16 14:30:05 +0200
committerKarel Zak2014-05-16 14:30:05 +0200
commit1efded63dfe85d62bcd8f0ff29ea6b62aa5cac74 (patch)
treeedd7ba4ca0fd2ace5752e384dd0005ea64a69ca7 /tests/ts
parentMerge branch 'tests-check-prog' of https://github.com/rudimeier/util-linux (diff)
parenttests: use ts_mount for cramfs (diff)
downloadkernel-qcow2-util-linux-1efded63dfe85d62bcd8f0ff29ea6b62aa5cac74.tar.gz
kernel-qcow2-util-linux-1efded63dfe85d62bcd8f0ff29ea6b62aa5cac74.tar.xz
kernel-qcow2-util-linux-1efded63dfe85d62bcd8f0ff29ea6b62aa5cac74.zip
Merge branch 'tests-mount' of https://github.com/rudimeier/util-linux
* 'tests-mount' of https://github.com/rudimeier/util-linux: tests: use ts_mount for cramfs tests: ts_mount knows which fs is expected tests: ts_mount validates error message tests, add function ts_mount
Diffstat (limited to 'tests/ts')
-rwxr-xr-xtests/ts/cramfs/doubles2
-rwxr-xr-xtests/ts/cramfs/mkfs2
-rwxr-xr-xtests/ts/minix/mkfs3
3 files changed, 3 insertions, 4 deletions
diff --git a/tests/ts/cramfs/doubles b/tests/ts/cramfs/doubles
index 7393fc7dc..43fc60330 100755
--- a/tests/ts/cramfs/doubles
+++ b/tests/ts/cramfs/doubles
@@ -46,7 +46,7 @@ ts_log "create cramfs image"
$TS_CMD_MKCRAMFS $IMAGE_SRC $IMAGE_PATH 2>&1 >> $TS_OUTPUT
[ -s "$IMAGE_PATH" ] || ts_die "Cannot create $IMAGE_PATH"
-$TS_CMD_MOUNT -r $IMAGE_PATH $TS_MOUNTPOINT 2>&1 >> $TS_OUTPUT
+ts_mount "cramfs" -r $IMAGE_PATH $TS_MOUNTPOINT
# check it
ts_is_mounted $TS_MOUNTPOINT || ts_die "Cannot find $TS_MOUNTPOINT in /proc/mounts"
diff --git a/tests/ts/cramfs/mkfs b/tests/ts/cramfs/mkfs
index 70c827591..06cdfbd32 100755
--- a/tests/ts/cramfs/mkfs
+++ b/tests/ts/cramfs/mkfs
@@ -77,7 +77,7 @@ ts_device_has "TYPE" "cramfs" $DEVICE
[ "$?" == "0" ] || ts_die "Cannot find cramfs on $DEVICE" $DEVICE
ts_log "mount the image"
-$TS_CMD_MOUNT -r -L $LABEL $TS_MOUNTPOINT 2>&1 >> $TS_OUTPUT
+ts_mount "cramfs" -r -L $LABEL $TS_MOUNTPOINT
# check it
ts_is_mounted $DEVICE || ts_die "Cannot find $DEVICE in /proc/mounts" $DEVICE
diff --git a/tests/ts/minix/mkfs b/tests/ts/minix/mkfs
index f94cb0a4d..86230f77c 100755
--- a/tests/ts/minix/mkfs
+++ b/tests/ts/minix/mkfs
@@ -37,8 +37,7 @@ ts_log "create mountpoint dir"
[ -d "$TS_MOUNTPOINT" ] || mkdir -p $TS_MOUNTPOINT
ts_log "mount the filesystem"
-($TS_CMD_MOUNT $DEVICE $TS_MOUNTPOINT 2>&1 >> $TS_OUTPUT || true) \
- | grep -q "unknown filesystem type" && ts_skip "mkfs: minix fs not supported by kernel"
+ts_mount "minix" $DEVICE $TS_MOUNTPOINT
# check it
ts_is_mounted $DEVICE || ts_die "Cannot find $DEVICE in /proc/mounts" $DEVICE