mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
tests: reduce amount of pvcreates
Reduce number of evualted pvcreate commands. Since 0 is default value used to fill missing params, and 0 is also 1st. value in array, it's being tested. Drop unused data_alignment_offset.
This commit is contained in:
parent
8756297a8d
commit
6336b5dedf
@ -906,7 +906,6 @@ class TestLvm(unittest.TestCase):
|
||||
pvmeta_copies = [0, 1, 2]
|
||||
pvmeta_size = [0, 255, 512, 1024]
|
||||
data_alignment = [0, 2048, 4096]
|
||||
data_alignment_offset = [1, 1, 1]
|
||||
zero = [0, 1]
|
||||
|
||||
device_names = TestLvm._get_pv_device_names()
|
||||
@ -927,26 +926,12 @@ class TestLvm(unittest.TestCase):
|
||||
|
||||
#Try a number of combinations and permutations
|
||||
for s in size:
|
||||
lvm.pvCreate(d, s)
|
||||
lvm.pvRemove(d)
|
||||
for copies in pvmeta_copies:
|
||||
lvm.pvCreate(d, s, copies)
|
||||
lvm.pvRemove(d)
|
||||
for pv_size in pvmeta_size:
|
||||
lvm.pvCreate(d, s, copies, pv_size)
|
||||
lvm.pvRemove(d)
|
||||
for align in data_alignment:
|
||||
lvm.pvCreate(d, s, copies, pv_size, align)
|
||||
lvm.pvRemove(d)
|
||||
for align_offset in data_alignment_offset:
|
||||
lvm.pvCreate(
|
||||
d, s, copies, pv_size, align,
|
||||
align * align_offset)
|
||||
lvm.pvRemove(d)
|
||||
for z in zero:
|
||||
lvm.pvCreate(
|
||||
d, s, copies, pv_size, align,
|
||||
align * align_offset, z)
|
||||
lvm.pvCreate(d, s, copies, pv_size, align,
|
||||
align, z)
|
||||
lvm.pvRemove(d)
|
||||
|
||||
#Restore
|
||||
|
Loading…
Reference in New Issue
Block a user