1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-03 05:18:29 +03:00

tests: add check sysfs_queue

Add check function for content of /sys/block/$1/queue/$2 == $3
This commit is contained in:
Zdenek Kabelac 2015-04-02 12:21:55 +02:00
parent 95dbedb301
commit 7a6e3838e9

View File

@ -365,6 +365,14 @@ dev_md5sum() {
die "LV $1/$2 has different MD5 check sum!")
}
sysfs_queue() {
# Verify optimal_io_size
local P="/sys/block/$1/queue/$2"
test -f "$P" || return 0
test "$(< $P)" -eq "$3" || \
die "$P = $(< $P) differs from expected value $3!"
}
#set -x
unset LVM_VALGRIND
"$@"