mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
tests: add check grep_dmsetup
Add simple helper/wrapper check function to check result of dmsetup call i.e.: check grep_dmsetup table vg-lv "grep_expected" check grep_dmsetup status vg-lv -v "grep_unexpected"
This commit is contained in:
parent
0e8449a5b9
commit
561f773bb4
@ -400,6 +400,11 @@ raid_leg_status() {
|
|||||||
die "$1-$2 status $val != $3 ($st)"
|
die "$1-$2 status $val != $3 ($st)"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
grep_dmsetup() {
|
||||||
|
dmsetup $1 $2 | tee out
|
||||||
|
grep "${@:3}" out || die "Expected output from dmsetup $1 not found!"
|
||||||
|
}
|
||||||
|
|
||||||
#set -x
|
#set -x
|
||||||
unset LVM_VALGRIND
|
unset LVM_VALGRIND
|
||||||
"$@"
|
"$@"
|
||||||
|
Loading…
Reference in New Issue
Block a user