summaryrefslogtreecommitdiffstats
path: root/tests/ts/libmount
diff options
context:
space:
mode:
authorRuediger Meier2018-01-24 00:20:15 +0100
committerRuediger Meier2018-03-07 18:36:17 +0100
commitaa00f7441d370d45996eec8d83bd00eff43721b5 (patch)
tree2f4e6e6ec11d2703a6900717cbbc4db0867fe291 /tests/ts/libmount
parenttests: add some more udevadm settle (diff)
downloadkernel-qcow2-util-linux-aa00f7441d370d45996eec8d83bd00eff43721b5.tar.gz
kernel-qcow2-util-linux-aa00f7441d370d45996eec8d83bd00eff43721b5.tar.xz
kernel-qcow2-util-linux-aa00f7441d370d45996eec8d83bd00eff43721b5.zip
tests: add wierd sleep for libmount/context
I still don't understand why this helps to fix these tests on my system. udevadm settle had no positive effect. Adding the sleeps before "is_mounted" also didn't fixed that, that's amazing!? Below the test log, very often seen on my system since a long time: -------------------- util-linux regression tests -------------------- For development purpose only. Don't execute on production system! kernel: 4.4.104-39-default libmount: context: [01] mount-by-devname ... OK libmount: context: [02] umount-by-devname ... OK libmount: context: [03] mount-by-label ... OK libmount: context: [04] umount-by-mountpoint ... OK libmount: context: [05] mount-by-uuid ... FAILED (libmount/context-mount-by-uuid) libmount: context: [06] mount-flags ... FAILED (libmount/context-mount-flags) libmount: context: [07] mount-loopdev ... OK libmount: context: [08] x-mount.mkdir ... OK libmount: context: [09] X-mount.mkdir ... OK libmount: context ... FAILED (2 from 9 sub-tests) --------------------------------------------------------------------- 1 tests of 17 FAILED --------------------------------------------------------------------- rudi@zappa:~/devel/util-linux/build> cat tests/diff/libmount/context-mount-by-uuid --- /home/rudi/devel/util-linux/tests/expected/libmount/context-mount-by-uuid 2017-07-03 12:20:24.144845538 +0200 +++ /home/rudi/devel/util-linux/build/tests/output/libmount/context-mount-by-uuid 2018-01-24 00:42:18.549444408 +0100 @@ -1,2 +1,3 @@ successfully mounted -successfully umounted +failed to umount +FAILED [rc=16]/dev/sdb1 still mounted rudi@zappa:~/devel/util-linux/build> cat tests/diff/libmount/context-mount-flags --- /home/rudi/devel/util-linux/tests/expected/libmount/context-mount-flags 2017-07-03 12:20:24.148845497 +0200 +++ /home/rudi/devel/util-linux/build/tests/output/libmount/context-mount-flags 2018-01-24 00:42:18.725442931 +0100 @@ -1,5 +1,5 @@ +test_mount_context: failed to mount: Device or resource busy +FAILED [rc=16]rw,relatime successfully mounted -ro,nosuid,noexec -successfully mounted -rw,nosuid,noexec +rw,relatime successfully umounted Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
Diffstat (limited to 'tests/ts/libmount')
-rwxr-xr-xtests/ts/libmount/context2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/ts/libmount/context b/tests/ts/libmount/context
index 3b49801d4..5a4f36afa 100755
--- a/tests/ts/libmount/context
+++ b/tests/ts/libmount/context
@@ -111,7 +111,9 @@ ts_init_subtest "mount-by-uuid"
mkdir -p $MOUNTPOINT &> /dev/null
ts_run $TESTPROG --mount UUID="$UUID" $MOUNTPOINT >> $TS_OUTPUT 2>&1
is_mounted $DEVICE || echo "$DEVICE not mounted" >> $TS_OUTPUT 2>&1
+sleep 1
ts_run $TESTPROG --umount $MOUNTPOINT >> $TS_OUTPUT 2>&1
+sleep 1
is_mounted $DEVICE && echo "$DEVICE still mounted" >> $TS_OUTPUT 2>&1
ts_finalize_subtest