mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-03 05:18:29 +03:00
fail testcase for failed commands inside the for loop
This commit is contained in:
parent
a4a1cd76ba
commit
6b7d2770f7
@ -54,35 +54,36 @@ test_expect_success "set up temp files, loopback devices" \
|
|||||||
lvcreate -n "$lv" -l 1%FREE -i5 -I256 "$vg"'
|
lvcreate -n "$lv" -l 1%FREE -i5 -I256 "$vg"'
|
||||||
|
|
||||||
test_expect_success "test *scan and *display tools" \
|
test_expect_success "test *scan and *display tools" \
|
||||||
'pvscan &&
|
'pvscan &&
|
||||||
vgscan &&
|
vgscan &&
|
||||||
lvscan &&
|
lvscan &&
|
||||||
for i in b k m g t p e H B K M G T P E ; do pvdisplay --units $i ; done &&
|
lvmdiskscan &&
|
||||||
vgdisplay --units k &&
|
vgdisplay --units k &&
|
||||||
lvdisplay --units g'
|
lvdisplay --units g &&
|
||||||
|
for i in b k m g t p e H B K M G T P E ; do \
|
||||||
|
pvdisplay --units "$i" "$d1" || return $? ; done'
|
||||||
|
|
||||||
test_expect_success "test vgexport vgimport tools" \
|
test_expect_success "test vgexport vgimport tools" \
|
||||||
'vgchange -an "$vg" &&
|
'vgchange -an "$vg" &&
|
||||||
vgexport "$vg" &&
|
vgexport "$vg" &&
|
||||||
vgimport "$vg" &&
|
vgimport "$vg" &&
|
||||||
vgchange -ay "$vg"'
|
vgchange -ay "$vg"'
|
||||||
|
|
||||||
# "-persistent y --major 254 --minor 20"
|
# "-persistent y --major 254 --minor 20"
|
||||||
|
# "-persistent n"
|
||||||
test_expect_success "test various lvm utils" \
|
test_expect_success "test various lvm utils" \
|
||||||
'lvmdiskscan &&
|
'for i in dumpconfig formats segtypes
|
||||||
for i in dumpconfig formats segtypes ; do lvm $i ; done &&
|
do lvm "$i" || return $? ; done &&
|
||||||
for i in pr \"p rw\" an ay -refresh "-monitor y" "-monitor n" \
|
for i in pr "p rw" an ay "-monitor y" "-monitor n" \
|
||||||
"-persistent n" -resync \
|
-resync -refresh "-addtag MYTAG" "-deltag MYETAG"
|
||||||
"-addtag MYTAG" "-deltag MYTAG"; \
|
do lvchange -$i "$vg"/"$lv" || return $? ; done &&
|
||||||
do lvchange -$i "$vg"/"$lv" ; done &&
|
pvck "$d1" &&
|
||||||
pvck "$d1" &&
|
vgck "$vg" &&
|
||||||
vgck "$vg" &&
|
lvrename "$vg" "$lv" "$lv-rename" &&
|
||||||
lvrename "$vg" "$lv" "$lv-rename" &&
|
vgcfgbackup -f "$(pwd)/backup.$$" "$vg" &&
|
||||||
vgcfgbackup -f $(pwd)/backup.$$ "$vg" &&
|
vgchange -an "$vg" &&
|
||||||
vgchange -an "$vg" &&
|
vgcfgrestore -f "$(pwd)/backup.$$" "$vg" &&
|
||||||
pvdisplay &&
|
vgremove -f "$vg" &&
|
||||||
vgcfgrestore -f $(pwd)/backup.$$ "$vg" &&
|
|
||||||
vgremove -f "$vg" &&
|
|
||||||
pvresize --setphysicalvolumesize 10M "$d1"'
|
pvresize --setphysicalvolumesize 10M "$d1"'
|
||||||
|
|
||||||
test_expect_failure "test various errors and obsoleted tools" \
|
test_expect_failure "test various errors and obsoleted tools" \
|
||||||
|
Loading…
Reference in New Issue
Block a user