diff options
Diffstat (limited to 'tests/functions.sh')
-rw-r--r-- | tests/functions.sh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/functions.sh b/tests/functions.sh index 86abfb4e9..6c0658b1b 100644 --- a/tests/functions.sh +++ b/tests/functions.sh @@ -99,4 +99,16 @@ function ts_device_deinit { rm -f "$IMAGE" &> /dev/null fi } + +function ts_udev_loop_support { + ldd $TS_CMD_MOUNT | grep -q 'libvolume_id' 2>&1 >> $TS_OUTPUT + if [ "$?" == "0" ]; then + HAS_VOLUMEID="yes" + fi + if [ -n "$HAS_VOLUMEID" ] && [ ! -L "/dev/disk/by-label/$1" ]; then + return 1 + fi + return 0 +} + |