mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-02 01:18:26 +03:00
tests: use should for expected state
While we heavily try to spot arrays that are not yet in-sync, some kernels tends to block our lvm2 command in kernel, while we resume these smaller raid arrays even for 5 seconds. But since the result is not really wrong - report these check failures only as TEST WARNING.
This commit is contained in:
parent
05eb90db68
commit
64a8505b96
@ -60,7 +60,7 @@ done
|
|||||||
|
|
||||||
# raid1 supports resynchronization
|
# raid1 supports resynchronization
|
||||||
lvcreate --type raid1 -m 2 -Zn -l 4 -n $lv1 $vg
|
lvcreate --type raid1 -m 2 -Zn -l 4 -n $lv1 $vg
|
||||||
check raid_leg_status $vg $lv1 "aaa"
|
should check raid_leg_status $vg $lv1 "aaa"
|
||||||
_sync "AAA"
|
_sync "AAA"
|
||||||
|
|
||||||
# raid1 supports --nosync
|
# raid1 supports --nosync
|
||||||
@ -72,7 +72,7 @@ for r in $segtypes
|
|||||||
do
|
do
|
||||||
# raid4/5 support resynchronization
|
# raid4/5 support resynchronization
|
||||||
lvcreate --type $r -Zn -i 3 -L10 -n $lv1 $vg
|
lvcreate --type $r -Zn -i 3 -L10 -n $lv1 $vg
|
||||||
check raid_leg_status $vg $lv1 "aaaa"
|
should check raid_leg_status $vg $lv1 "aaaa"
|
||||||
_sync "AAAA"
|
_sync "AAAA"
|
||||||
|
|
||||||
# raid4/5 support --nosync
|
# raid4/5 support --nosync
|
||||||
@ -83,7 +83,7 @@ done
|
|||||||
|
|
||||||
# raid6 supports resynchronization
|
# raid6 supports resynchronization
|
||||||
lvcreate --type raid6 -Zn -i 3 -l 4 -n $lv1 $vg
|
lvcreate --type raid6 -Zn -i 3 -l 4 -n $lv1 $vg
|
||||||
check raid_leg_status $vg $lv1 "aaaaa"
|
should check raid_leg_status $vg $lv1 "aaaaa"
|
||||||
_sync "AAAAA"
|
_sync "AAAAA"
|
||||||
|
|
||||||
# raid6 rejects --nosync; it has to initialize P- and Q-Syndromes
|
# raid6 rejects --nosync; it has to initialize P- and Q-Syndromes
|
||||||
@ -91,7 +91,7 @@ not lvcreate --type raid6 --nosync -Zn -i 3 -l 1 -n $lv1 $vg
|
|||||||
|
|
||||||
# raid10 supports resynchronization
|
# raid10 supports resynchronization
|
||||||
lvcreate --type raid10 -m 1 -Zn -i 3 -L10 -n $lv1 $vg
|
lvcreate --type raid10 -m 1 -Zn -i 3 -L10 -n $lv1 $vg
|
||||||
check raid_leg_status $vg $lv1 "aaaaaa"
|
should check raid_leg_status $vg $lv1 "aaaaaa"
|
||||||
_sync "AAAAAA"
|
_sync "AAAAAA"
|
||||||
|
|
||||||
# raid10 supports --nosync
|
# raid10 supports --nosync
|
||||||
|
Loading…
Reference in New Issue
Block a user