[parted-devel] [PATCH] tests: verify that 'udevadm settle' is available
Petr Uzel
petr.uzel at suse.cz
Mon Oct 3 13:00:58 UTC 2011
* tests/init.cfg (require_udevadm_settle_): New function.
* tests/t8001-loop-blkpg.sh: Call it.
---
tests/init.cfg | 6 ++++++
tests/t8001-loop-blkpg.sh | 1 +
2 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/tests/init.cfg b/tests/init.cfg
index 08ebd0c..ca4dffc 100644
--- a/tests/init.cfg
+++ b/tests/init.cfg
@@ -25,6 +25,12 @@ require_512_byte_sector_size_()
test $sector_size_ = 512 || skip_ 'FS test with sector size != 512'
}
+require_udevadm_settle_()
+{
+ udevadm settle --help \
+ || skip_ 'udevadm command is required for this test'
+}
+
# We need two cleanup functions. One, cleanup_final_, is sometimes
# used (transparently) via t-local.sh's modprobe/rmmod code.
# The other is used e.g., to unmount.
diff --git a/tests/t8001-loop-blkpg.sh b/tests/t8001-loop-blkpg.sh
index f6e37ce..08d8f47 100755
--- a/tests/t8001-loop-blkpg.sh
+++ b/tests/t8001-loop-blkpg.sh
@@ -19,6 +19,7 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../parted
require_root_
+require_udevadm_settle_
cleanup_fn_()
{
--
1.7.3.4
More information about the parted-devel
mailing list