diff options
author | Karel Zak | 2011-09-29 20:50:27 +0200 |
---|---|---|
committer | Karel Zak | 2011-09-29 20:50:27 +0200 |
commit | faa9d6431f831bcf6b6f3d962da7451a4d3e9e7f (patch) | |
tree | 1f42dc498e6b079a73fdc380177a4b041cc0ac9f /tests/ts/libmount/context | |
parent | libmount: support {offset,sizelimit}= foor loopdevs (diff) | |
download | kernel-qcow2-util-linux-faa9d6431f831bcf6b6f3d962da7451a4d3e9e7f.tar.gz kernel-qcow2-util-linux-faa9d6431f831bcf6b6f3d962da7451a4d3e9e7f.tar.xz kernel-qcow2-util-linux-faa9d6431f831bcf6b6f3d962da7451a4d3e9e7f.zip |
tests: add loopdev libmount test
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'tests/ts/libmount/context')
-rwxr-xr-x | tests/ts/libmount/context | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/ts/libmount/context b/tests/ts/libmount/context index 0b1009823..5a01caebc 100755 --- a/tests/ts/libmount/context +++ b/tests/ts/libmount/context @@ -116,6 +116,18 @@ grep -q $DEVICE $LIBMOUNT_MTAB && ts_finalize_subtest +ts_init_subtest "mount-loopdev" +mkdir -p $MOUNTPOINT &> /dev/null +img=$(ts_image_init) +mkfs.ext3 -F $img &> /dev/null +$TESTPROG --mount -o loop $img $MOUNTPOINT >> $TS_OUTPUT 2>&1 +grep -q $MOUNTPOINT $LIBMOUNT_MTAB || \ + echo "(loopdev) cannot find $MOUNTPOINT in $LIBMOUNT_MTAB" >> $TS_OUTPUT 2>&1 +$TESTPROG --umount $MOUNTPOINT >> $TS_OUTPUT 2>&1 +grep -q $MOUNTPOINT $LIBMOUNT_MTAB && + echo "umount failed: found $MOUNTPOINT in $LIBMOUNT_MTAB" >> $TS_OUTPUT 2>&1 +ts_finalize_subtest + ts_log "...done." rmmod scsi_debug ts_finalize |