]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
tests: call valgrind from libmount utils and update tests
authorKarel Zak <kzak@redhat.com>
Thu, 26 Jan 2012 13:27:09 +0000 (14:27 +0100)
committerKarel Zak <kzak@redhat.com>
Thu, 26 Jan 2012 13:27:09 +0000 (14:27 +0100)
Signed-off-by: Karel Zak <kzak@redhat.com>
tests/ts/libmount/update
tests/ts/libmount/utils

index 333605aa9efd84bab95c034645317437caaf9621..3a989dddb8b0b6482bab10d152ed3c59202ec395 100755 (executable)
@@ -30,30 +30,30 @@ rm -f $LIBMOUNT_MTAB
 > $LIBMOUNT_MTAB
 
 ts_init_subtest "mtab-mount"
-$TESTPROG --add /dev/sda1 /mnt/foo ext3 "rw,bbb,ccc,fff=FFF,ddd,noexec"
-$TESTPROG --add /dev/sdb1 /mnt/bar ext3 "gg=G,ffff=f,ro,noatime"
-$TESTPROG --add /dev/sda2 /mnt/bar ext3 "rw,noatime"
-$TESTPROG --add /dev/sda1 /mnt/gogo ext3 "rw,noatime,nosuid"
-$TESTPROG --add none /proc proc defaults
+ts_valgrind $TESTPROG --add /dev/sda1 /mnt/foo ext3 "rw,bbb,ccc,fff=FFF,ddd,noexec"
+ts_valgrind $TESTPROG --add /dev/sdb1 /mnt/bar ext3 "gg=G,ffff=f,ro,noatime"
+ts_valgrind $TESTPROG --add /dev/sda2 /mnt/bar ext3 "rw,noatime"
+ts_valgrind $TESTPROG --add /dev/sda1 /mnt/gogo ext3 "rw,noatime,nosuid"
+ts_valgrind $TESTPROG --add none /proc proc defaults
 cp $LIBMOUNT_MTAB $TS_OUTPUT   # save the mtab aside
 ts_finalize_subtest            # checks the mtab
 
 ts_init_subtest "mtab-move"
-$TESTPROG --move /mnt/foo /mnt/newfoo
-$TESTPROG --move /mnt/bar /mnt/newbar
+ts_valgrind $TESTPROG --move /mnt/foo /mnt/newfoo
+ts_valgrind $TESTPROG --move /mnt/bar /mnt/newbar
 cp $LIBMOUNT_MTAB $TS_OUTPUT   # save the mtab aside
 ts_finalize_subtest            # checks the mtab
 
 ts_init_subtest "mtab-remount"
-$TESTPROG --remount /mnt/newfoo "ro,noatime"
-$TESTPROG --remount /mnt/bar "rw,atime,nosuid"
+ts_valgrind $TESTPROG --remount /mnt/newfoo "ro,noatime"
+ts_valgrind $TESTPROG --remount /mnt/bar "rw,atime,nosuid"
 cp $LIBMOUNT_MTAB $TS_OUTPUT   # save the mtab aside
 ts_finalize_subtest            # checks the mtab
 
 ts_init_subtest "mtab-umount"
-$TESTPROG --remove /mnt/bar
-$TESTPROG --remove /mnt/gogo
-$TESTPROG --remove /proc
+ts_valgrind $TESTPROG --remove /mnt/bar
+ts_valgrind $TESTPROG --remove /mnt/gogo
+ts_valgrind $TESTPROG --remove /proc
 cp $LIBMOUNT_MTAB $TS_OUTPUT   # save the mtab aside
 ts_finalize_subtest            # checks the mtab
 
@@ -68,28 +68,28 @@ rm -f $LIBMOUNT_UTAB
 > $LIBMOUNT_UTAB
 
 ts_init_subtest "utab-mount"
-$TESTPROG --add /dev/sda1 /mnt/foo ext3 "rw,bbb,ccc,fff=FFF,ddd,noexec"
-$TESTPROG --add /dev/sdb1 /mnt/bar ext3 "ro,user"
-$TESTPROG --add /dev/sda2 /mnt/xyz ext3 "rw,loop=/dev/loop0,uhelper=hal"
-$TESTPROG --add none /proc proc "rw,user"
+ts_valgrind $TESTPROG --add /dev/sda1 /mnt/foo ext3 "rw,bbb,ccc,fff=FFF,ddd,noexec"
+ts_valgrind $TESTPROG --add /dev/sdb1 /mnt/bar ext3 "ro,user"
+ts_valgrind $TESTPROG --add /dev/sda2 /mnt/xyz ext3 "rw,loop=/dev/loop0,uhelper=hal"
+ts_valgrind $TESTPROG --add none /proc proc "rw,user"
 cp $LIBMOUNT_UTAB $TS_OUTPUT   # save the mtab aside
 ts_finalize_subtest            # checks the mtab
 
 ts_init_subtest "utab-move"
-$TESTPROG --move /mnt/bar /mnt/newbar
-$TESTPROG --move /mnt/xyz /mnt/newxyz
+ts_valgrind $TESTPROG --move /mnt/bar /mnt/newbar
+ts_valgrind $TESTPROG --move /mnt/xyz /mnt/newxyz
 cp $LIBMOUNT_UTAB $TS_OUTPUT   # save the mtab aside
 ts_finalize_subtest            # checks the mtab
 
 ts_init_subtest "utab-remount"
-$TESTPROG --remount /mnt/newbar "ro,noatime"
-$TESTPROG --remount /mnt/newxyz "rw,user"
+ts_valgrind $TESTPROG --remount /mnt/newbar "ro,noatime"
+ts_valgrind $TESTPROG --remount /mnt/newxyz "rw,user"
 cp $LIBMOUNT_UTAB $TS_OUTPUT   # save the mtab aside
 ts_finalize_subtest            # checks the mtab
 
 ts_init_subtest "utab-umount"
-$TESTPROG --remove /mnt/newbar
-$TESTPROG --remove /proc
+ts_valgrind $TESTPROG --remove /mnt/newbar
+ts_valgrind $TESTPROG --remove /proc
 cp $LIBMOUNT_UTAB $TS_OUTPUT   # save the mtab aside
 ts_finalize_subtest            # checks the mtab
 
index fbd63593b8dac0e9ee5b56221c3968e3c4bca6f8..d425400adfe85d707877db6e5ffcf4ca670c1324 100755 (executable)
@@ -13,67 +13,67 @@ 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_valgrind $TESTPROG --match-fstype ext3 "ext2,ext3,cifs" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "match-fstype-neg"
-$TESTPROG --match-fstype cifs "ext2,ext3,nocifs" &> $TS_OUTPUT
+ts_valgrind $TESTPROG --match-fstype cifs "ext2,ext3,nocifs" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "match-fstype-neg2"
-$TESTPROG --match-fstype cifs "noext2,ext3,cifs" &> $TS_OUTPUT
+ts_valgrind $TESTPROG --match-fstype cifs "noext2,ext3,cifs" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "match-options"
-$TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "ccc" &> $TS_OUTPUT
+ts_valgrind $TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "ccc" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "match-options-list"
-$TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "ccc,aaa,ddd" &> $TS_OUTPUT
+ts_valgrind $TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "ccc,aaa,ddd" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "match-options-neg"
-$TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "noxxx" &> $TS_OUTPUT
+ts_valgrind $TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "noxxx" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "match-options-neg-list"
-$TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "ddd,noaaa" &> $TS_OUTPUT
+ts_valgrind $TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "ddd,noaaa" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "match-options-neg-list2"
-$TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "noxxx,ccc,aaa" &> $TS_OUTPUT
+ts_valgrind $TESTPROG --match-options "aaa,bbb=BBB,ccc,ddd" "noxxx,ccc,aaa" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "starts-with"
-$TESTPROG --starts-with "AAAbbbCCC" "AAA" &> $TS_OUTPUT
+ts_valgrind $TESTPROG --starts-with "AAAbbbCCC" "AAA" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "ends-with"
-$TESTPROG --ends-with "AAAbbbCCC" "CCC" &> $TS_OUTPUT
+ts_valgrind $TESTPROG --ends-with "AAAbbbCCC" "CCC" &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "mountpoint"
-$TESTPROG --mountpoint /proc &> $TS_OUTPUT
+ts_valgrind $TESTPROG --mountpoint /proc &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "mountpoint-subdir"
-$TESTPROG --mountpoint /proc/sys/kernel &> $TS_OUTPUT
+ts_valgrind $TESTPROG --mountpoint /proc/sys/kernel &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "mountpoint-root"
-$TESTPROG --mountpoint / &> $TS_OUTPUT
+ts_valgrind $TESTPROG --mountpoint / &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "fs-root"
-$TESTPROG --fs-root /proc &> $TS_OUTPUT
+ts_valgrind $TESTPROG --fs-root /proc &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "fs-root-subdir"
-$TESTPROG --fs-root /proc/sys/kernel &> $TS_OUTPUT
+ts_valgrind $TESTPROG --fs-root /proc/sys/kernel &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_init_subtest "fs-root-subdir2"
-$TESTPROG --fs-root /etc &> $TS_OUTPUT
+ts_valgrind $TESTPROG --fs-root /etc &> $TS_OUTPUT
 ts_finalize_subtest
 
 ts_finalize