From: Bernhard Voelker Date: Fri, 27 Jul 2012 09:00:17 +0000 (+0200) Subject: tests: use ts_is_mounted in mount/regfile X-Git-Tag: v2.22-rc2~61 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=018a38a64cda88b0402f55b616ef58168be1f7e9;p=thirdparty%2Futil-linux.git tests: use ts_is_mounted in mount/regfile If the test directory is on a symlink, then mount/regfile failed because it did not search for the mount point in /proc/mounts canonicalized. Signed-off-by: Bernhard Voelker --- diff --git a/tests/ts/mount/regfile b/tests/ts/mount/regfile index c47c7d7950..8d786adbf3 100755 --- a/tests/ts/mount/regfile +++ b/tests/ts/mount/regfile @@ -21,7 +21,7 @@ $TS_CMD_MOUNT $IMAGE $TS_MOUNTPOINT 2>&1 >> $TS_OUTPUT DEVICE=$(awk '/regfile/ { print $1 }' /proc/mounts) -grep -q "$TS_MOUNTPOINT" /proc/mounts || ts_die "Cannot find $TS_MOUNTPOINT in /proc/mounts" +ts_is_mounted "$TS_MOUNTPOINT" || ts_die "Cannot find $TS_MOUNTPOINT in /proc/mounts" if [ -f "/sys/block/$(basename $DEVICE)/loop/backing_file" ]; then $TS_CMD_UMOUNT $IMAGE || ts_die "Cannot umount $IMAGE" @@ -30,7 +30,7 @@ else ts_skip "too old kernel" fi -grep -q "$TS_MOUNTPOINT" /proc/mounts && ts_die "$TS_MOUNTPOINT still in /proc/mounts" +ts_is_mounted "$TS_MOUNTPOINT" && ts_die "$TS_MOUNTPOINT still in /proc/mounts" ts_log "Success" ts_finalize