diff options
author | Dieter Plaetinck <dieter@plaetinck.be> | 2009-07-21 22:11:47 +0200 |
---|---|---|
committer | Dieter Plaetinck <dieter@plaetinck.be> | 2009-07-21 22:11:47 +0200 |
commit | 3bd20bde1e49ab664cc53262ec5ebb3e6323d3f6 (patch) | |
tree | bd7e686e44c3f4e62dc83712b7be94b0e550d204 /tests/lib/test-lvm-lv | |
parent | d982d8e1f9e6b806d44340ca28858e388a1fded7 (diff) |
make tests separate reusable files + make the testing thing a bit better
Diffstat (limited to 'tests/lib/test-lvm-lv')
-rw-r--r-- | tests/lib/test-lvm-lv | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/lib/test-lvm-lv b/tests/lib/test-lvm-lv new file mode 100644 index 0000000..2c6a6bc --- /dev/null +++ b/tests/lib/test-lvm-lv @@ -0,0 +1,9 @@ +#!/bin/bash +# $1 VG +# $2 LV +# $2 SIZE eg '800.00 MB' + +NAME="LOGICAL VOLUME CHECK, /dev/mapper/$1-$2" + +lvdisplay | grep -A 5 'LV Name.*/dev/mapper/'$1-$2 | grep -q available || exit 1 +lvdisplay | grep -A 7 'LV Name.*/dev/mapper/'$1-$2 | grep -q 'LV Size.*'"$2" || exit 2 |