tests: testdriver: Have all pools use pool- prefix

Signed-off-by: Cole Robinson <crobinso@redhat.com>
This commit is contained in:
Cole Robinson 2022-02-27 13:30:46 -05:00
parent 435c7181f1
commit 1f20ef7e07
10 changed files with 40 additions and 39 deletions

View File

@ -251,7 +251,7 @@
</disk>
<disk type="block" device="lun" sgio="unfiltered" rawio="yes">
<driver name="qemu" type="raw"/>
<source dev="/iscsi-pool/diskvol1"/>
<source dev="/pool-iscsi/diskvol1"/>
<target dev="sdab" bus="scsi"/>
<iotune>
<total_bytes_sec>10</total_bytes_sec>
@ -285,7 +285,7 @@
</disk>
<disk type="volume" device="disk">
<driver name="qemu" type="raw"/>
<source volume="some-rbd-vol" pool="rbd-ceph"/>
<source volume="some-rbd-vol" pool="pool-rbd-ceph"/>
<target dev="vdf" bus="virtio"/>
</disk>
<disk type="network" device="disk">

View File

@ -20,7 +20,7 @@
<emulator>/usr/lib64/xen/bin/qemu-dm</emulator>
<disk type="block" device="disk">
<driver name="phy"/>
<source dev="/iscsi-pool/diskvol1"/>
<source dev="/pool-iscsi/diskvol1"/>
<target dev="hda" bus="ide"/>
</disk>
<disk type="file" device="cdrom">

View File

@ -261,7 +261,7 @@ Foo bar baz &amp; yeah boii &lt; &gt; yeahfoo
<!-- bus virtio -->
<disk type="volume" device="disk">
<driver name="qemu"/>
<source pool="rbd-ceph" volume="vol1"/>
<source pool="pool-rbd-ceph" volume="vol1"/>
<target dev="vdb" bus="virtio"/>
<readonly/>
</disk>
@ -903,7 +903,7 @@ test-many-devices, like an alternate RNG, EOL OS ID, title field
<devices>
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
<disk type='block' device='disk'>
<source dev='/full-pool/testvol1.img'/>
<source dev='/pool-test-full-pool/testvol1.img'/>
<target dev='hda' bus='ide'/>
</disk>
<interface type='user'>
@ -1824,7 +1824,7 @@ ba</description>
<pool type='dir'>
<name>spurious-slash-pool</name>
<name>pool-test-spurious-slash</name>
<uuid>35bb2ad9-1122-cdfe-461a-b8907f6e53fe</uuid>
<capacity>107374182400</capacity>
<allocation>0</allocation>
@ -1832,7 +1832,7 @@ ba</description>
<source>
</source>
<target>
<path>/spurious-slash-pool//</path>
<path>/pool-test-spurious-splash//</path>
<permissions>
<mode>0700</mode>
<owner>10736</owner>
@ -1868,7 +1868,7 @@ ba</description>
<pool type='dir'>
<name>inactive-pool</name>
<name>pool-test-inactive</name>
<uuid>35bb2aaa-388a-cdfe-461a-b8907f6e53fe</uuid>
<capacity>107374182400</capacity>
<allocation>0</allocation>
@ -1876,7 +1876,7 @@ ba</description>
<source>
</source>
<target>
<path>/inactive-pool</path>
<path>/pool-test-inactive</path>
<permissions>
<mode>0700</mode>
<owner>10736</owner>
@ -1901,7 +1901,7 @@ ba</description>
<pool type='dir'>
<name>cross-pool</name>
<name>pool-test-cross-pool</name>
<uuid>35bb2ad9-388a-cdfe-461a-b8907f6e5abc</uuid>
<capacity>107374182400</capacity>
<allocation>0</allocation>
@ -1909,7 +1909,7 @@ ba</description>
<source>
</source>
<target>
<path>/dev/cross-pool</path>
<path>/dev/pool-test-cross-pool</path>
<permissions>
<mode>0700</mode>
<owner>10736</owner>
@ -1946,7 +1946,7 @@ ba</description>
<pool type='dir'>
<name>full-pool</name>
<name>pool-test-full-pool</name>
<uuid>35bb2ad9-388a-cdfe-461a-b8907f6e5555</uuid>
<capacity>1</capacity>
<allocation>1</allocation>
@ -1954,7 +1954,7 @@ ba</description>
<source>
</source>
<target>
<path>/full-pool</path>
<path>/pool-test-full-pool</path>
<permissions>
<mode>0700</mode>
<owner>10736</owner>
@ -2062,7 +2062,7 @@ ba</description>
<pool type='iscsi'>
<name>iscsi-pool</name>
<name>pool-iscsi</name>
<uuid>abcdead9-388a-cdfe-461a-b8907f6e5aaa</uuid>
<capacity>107374182400</capacity>
<allocation>0</allocation>
@ -2072,7 +2072,7 @@ ba</description>
<device path="demo-target"/>
</source>
<target>
<path>/iscsi-pool</path>
<path>/pool-iscsi</path>
<permissions>
<mode>0700</mode>
<owner>10736</owner>
@ -2097,7 +2097,7 @@ ba</description>
<pool type='iscsi-direct'>
<name>iscsi-direct</name>
<name>pool-iscsi-direct</name>
<uuid>0799697a-94dd-4115-9601-8714b1931248</uuid>
<capacity unit='bytes'>524287488</capacity>
<allocation unit='bytes'>524287488</allocation>
@ -2125,7 +2125,7 @@ ba</description>
</pool>
<pool type='rbd'>
<name>rbd-ceph</name>
<name>pool-rbd-ceph</name>
<uuid>4bcd023e-990e-fcf6-d95c-52dd0cd938c8</uuid>
<capacity unit='bytes'>47256127143936</capacity>
<allocation unit='bytes'>5537792235090</allocation>
@ -2165,7 +2165,7 @@ ba</description>
<pool type='sheepdog'>
<name>myshpool</name>
<name>pool-sheepdog</name>
<uuid>581381f8-a13f-4f7c-89b5-9c9b71c64834</uuid>
<capacity unit='bytes'>107374182400</capacity>
<allocation unit='bytes'>53687091200</allocation>
@ -2194,7 +2194,7 @@ ba</description>
<pool type='gluster'>
<name>gluster-pool</name>
<name>pool-gluster</name>
<uuid>7b83ef6d-28da-44f1-841f-2011320f13b0</uuid>
<capacity unit='bytes'>492258959360</capacity>
<allocation unit='bytes'>16975638528</allocation>
@ -2256,7 +2256,7 @@ ba</description>
<pool type="zfs">
<name>zfs</name>
<name>pool-zfs</name>
<source>
<name>testzfspool</name>
<device path="/dev/ada1"/>
@ -2264,7 +2264,7 @@ ba</description>
</pool>
<pool type="dir">
<name>nvram</name>
<name>pool-test-nvram</name>
<source>
</source>
<target>
@ -2304,7 +2304,7 @@ ba</description>
</pool>
<pool type='mpath'>
<name>mpath</name>
<name>pool-mpath</name>
<target>
<path>/dev/mapper</path>
</target>
@ -2312,7 +2312,7 @@ ba</description>
<pool type='scsi'>
<name>scsi</name>
<name>pool-scsi</name>
<source>
<adapter type='scsi_host' name='host0'/>
</source>

View File

@ -573,11 +573,11 @@ memorytune0.vcpus=0-3,memorytune0.node0.id=0,memorytune0.node0.bandwidth=60
--disk source.file=%(NEWIMG1)s,sparse=false,size=.001,perms=ro,error_policy=enospace,detect_zeroes=unmap,address.type=drive,address.controller=0,address.target=2,address.unit=0
--disk device=cdrom,bus=sata,read_bytes_sec=1,read_iops_sec=2,write_bytes_sec=5,write_iops_sec=6,driver.copy_on_read=on,geometry.cyls=16383,geometry.heads=16,geometry.secs=63,geometry.trans=lba,discard=ignore
--disk size=1
--disk /iscsi-pool/diskvol1,total_bytes_sec=10,total_iops_sec=20,bus=scsi,device=lun,sgio=unfiltered,rawio=yes
--disk /pool-iscsi/diskvol1,total_bytes_sec=10,total_iops_sec=20,bus=scsi,device=lun,sgio=unfiltered,rawio=yes
--disk /pool-dir/iso-vol,seclabel.model=dac,seclabel1.model=selinux,seclabel1.relabel=no,seclabel0.label=foo,bar,baz,iotune.read_bytes_sec=1,iotune.read_iops_sec=2,iotune.write_bytes_sec=5,iotune.write_iops_sec=6
--disk /pool-dir/iso-vol,format=qcow2,startup_policy=optional,iotune.total_bytes_sec=10,iotune.total_iops_sec=20,
--disk source_pool=rbd-ceph,source_volume=some-rbd-vol,size=.1,driver_type=raw,driver_name=qemu
--disk pool=rbd-ceph,size=.1,driver.name=qemu,driver.type=raw,driver.discard=unmap,driver.detect_zeroes=unmap,driver.io=native,driver.error_policy=stop
--disk source_pool=pool-rbd-ceph,source_volume=some-rbd-vol,size=.1,driver_type=raw,driver_name=qemu
--disk pool=pool-rbd-ceph,size=.1,driver.name=qemu,driver.type=raw,driver.discard=unmap,driver.detect_zeroes=unmap,driver.io=native,driver.error_policy=stop
--disk source_protocol=http,source_host_name=example.com,source_host_port=8000,source_name=/path/to/my/file
--disk source.protocol=http,source.host0.name=exampl2.com,source.host.port=8000,source.name=/path/to/my/file
--disk source.protocol=nbd,source.host.transport=unix,source.host.socket=/tmp/socket,snapshot_policy=no
@ -585,13 +585,13 @@ memorytune0.vcpus=0-3,memorytune0.node0.id=0,memorytune0.node0.bandwidth=60
--disk gluster://192.168.1.100/test-volume/some/dir/test-gluster.qcow2
--disk nbd+unix:///var/foo/bar/socket,bus=usb,removable=on,address.type=usb,address.bus=0,address.port=2
--disk path=http://[1:2:3:4:1:2:3:4]:5522/my/path?query=foo
--disk vol=gluster-pool/test-gluster.raw
--disk vol=pool-gluster/test-gluster.raw
--disk /var,device=floppy,snapshot=no,perms=rw
--disk %(NEWIMG2)s,size=1,backing_store=/tmp/foo.img,backing_format=vmdk,bus=usb,target.removable=yes
--disk /tmp/brand-new.img,size=1,backing_store=/pool-dir/iso-vol,boot.order=10,boot.loadparm=5
--disk path=/dev/pool-logical/diskvol7,device=lun,bus=scsi,reservations.managed=no,reservations.source.type=unix,reservations.source.path=/var/run/test/pr-helper0.sock,reservations.source.mode=client,\
source.reservations.managed=no,source.reservations.source.type=unix,source.reservations.source.path=/var/run/test/pr-helper0.sock,source.reservations.source.mode=client,target.rotation_rate=6000
--disk vol=iscsi-direct/unit:0:0:1
--disk vol=pool-iscsi-direct/unit:0:0:1
--disk size=.0001,format=raw,transient=on,transient.shareBacking=yes
--disk size=.0001,pool=pool-logical
--disk path=%(EXISTIMG1)s,type=dir
@ -913,7 +913,7 @@ c.add_invalid("--disk %(NEWIMG1)s", grep="Size must be specified") # Not specif
c.add_invalid("--disk %(NEWIMG1)s,sparse=true,size=100000000000", grep="The requested volume capacity will exceed") # Fail if fully allocated file would exceed disk space
c.add_invalid("--connect %(URI-TEST-FULL)s --disk %(COLLIDE)s --prompt", grep="already in use by other guests") # Colliding storage with --prompt should still fail
c.add_invalid("--connect %(URI-TEST-FULL)s --disk /pool-dir/backingl3.img", grep="already in use by other guests") # Colliding storage via backing store
c.add_invalid("--connect %(URI-TEST-FULL)s --disk source_pool=rbd-ceph,source_volume=vol1", grep="already in use by other guests") # Collision with existing VM, via source pool/volume
c.add_invalid("--connect %(URI-TEST-FULL)s --disk source_pool=pool-rbd-ceph,source_volume=vol1", grep="already in use by other guests") # Collision with existing VM, via source pool/volume
c.add_invalid("--disk source.pool=pool-dir,source.volume=idontexist", grep="no storage vol with matching name 'idontexist'") # trying to lookup non-existent volume, hit specific error code
c.add_invalid("--disk size=1 --seclabel model=foo,type=bar", grep="not appear to have been successful") # Libvirt will error on the invalid security params, which should trigger the code path to clean up the disk images we created.
c.add_invalid("--disk size=1 --file foobar", grep="Cannot mix --file") # --disk and --file collision
@ -1198,8 +1198,8 @@ c = vinst.add_category("xen", "--noautoconsole --connect " + utils.URIs.xen)
c.add_valid("--disk %(EXISTIMG1)s --location %(TREEDIR)s --paravirt --graphics none") # Xen PV install headless
c.add_compare("--disk %(EXISTIMG1)s --import", "xen-default") # Xen default
c.add_compare("--disk %(EXISTIMG1)s --location %(TREEDIR)s --paravirt --controller xenbus,maxGrantFrames=64 --input default", "xen-pv", precompare_check="5.3.0") # Xen PV
c.add_compare("--osinfo generic --disk /iscsi-pool/diskvol1 --cdrom %(EXISTIMG1)s --livecd --hvm", "xen-hvm") # Xen HVM
c.add_compare("--osinfo generic --disk /iscsi-pool/diskvol1 --cdrom %(EXISTIMG1)s --install no_install=yes --hvm", "xen-hvm") # Ensure --livecd and --install no_install are essentially identical
c.add_compare("--osinfo generic --disk /pool-iscsi/diskvol1 --cdrom %(EXISTIMG1)s --livecd --hvm", "xen-hvm") # Xen HVM
c.add_compare("--osinfo generic --disk /pool-iscsi/diskvol1 --cdrom %(EXISTIMG1)s --install no_install=yes --hvm", "xen-hvm") # Ensure --livecd and --install no_install are essentially identical
@ -1486,7 +1486,7 @@ c.add_compare("--connect %(URI-KVM-X86)s " + _CLONE_NVRAM_MISSING + " --auto-clo
c.add_compare("--connect %(URI-KVM-X86)s -o test-clone -n test-newclone --mac 12:34:56:1A:B2:C3 --mac 12:34:56:1A:B7:C3 --uuid 12345678-12F4-1234-1234-123456789AFA --file /dev/pool-logical/newclone1.img --file /pool-dir/newclone2.img --skip-copy=hdb --force-copy=sdb --file /pool-dir/newclone3.img", "clone-manual")
c.add_compare("--connect %(URI-KVM-X86)s -o test-clone -n test-newclone --mac 12:34:56:1A:B2:C3 --mac 12:34:56:1A:B7:C3 --uuid 12345678-12F4-1234-1234-123456789AFA --file /dev/pool-logical/newclone1.img --file /pool-dir/newclone2.img --skip-copy=hdb --force-copy=sdb --file /pool-dir/newclone3.img", "clone-manual")
c.add_compare(_CLONE_EMPTY + " --auto-clone --print-xml", "empty") # Auto flag, no storage
c.add_compare("--connect %(URI-KVM-X86)s -o test-clone-simple --auto -f /foo.img --print-xml", "cross-pool") # cross pool cloning which fails with test driver but let's confirm the XML
c.add_compare("--connect %(URI-KVM-X86)s -o test-clone-simple --auto -f /foo.img --print-xml", "pool-test-cross-pool") # cross pool cloning which fails with test driver but let's confirm the XML
c.add_compare(_CLONE_MANAGED + " --auto-clone", "auto-managed") # Auto flag w/ managed storage
c.add_compare(_CLONE_UNMANAGED + " --auto-clone", "auto-unmanaged") # Auto flag w/ local storage
c.add_valid("--connect %(URI-TEST-FULL)s -o test-clone --auto-clone --nonsparse") # Auto flag, actual VM, skip state check

View File

@ -217,7 +217,7 @@ def testMisc():
assert vol.is_size_conflict()[0] is False
fullconn = utils.URIs.open_testdriver_cached()
glusterpool = fullconn.storagePoolLookupByName("gluster-pool")
glusterpool = fullconn.storagePoolLookupByName("pool-gluster")
diskpool = fullconn.storagePoolLookupByName("pool-logical")
glustervol = StorageVolume(fullconn)
@ -232,8 +232,8 @@ def testMisc():
StoragePool.ensure_pool_is_running(glusterpool)
# Check pool collision detection
name = StoragePool.find_free_name(fullconn, "gluster-pool")
assert name == "gluster-pool-1"
name = StoragePool.find_free_name(fullconn, "pool-gluster")
assert name == "pool-gluster-1"
def testEnumerateLogical():

View File

@ -120,7 +120,7 @@ def testAddCephDisk(app):
tab.find_fuzzy("Select or create", "radio").click()
tab.find("storage-browse", "push button").click()
browse = app.root.find("vmm-storage-browser")
browse.find_fuzzy("rbd-ceph", "table cell").bring_on_screen().click()
browse.find_fuzzy("pool-rbd-ceph", "table cell").bring_on_screen().click()
browse.find_fuzzy("some-rbd-vol", "table cell").click()
browse.find("Choose Volume", "push button").click()
_finish(addhw, check=details)

View File

@ -75,8 +75,8 @@ def testCreatePools(app):
# Test a iscsi pool
win = _open_createpool(app, hostwin)
win.combo_select("Type:", "iscsi:")
newname = "a-iscsi-pool"
name.set_text("a-iscsi-pool")
newname = "a-pool-iscsi"
name.set_text("a-pool-iscsi")
win.find("target-browse").click()
_browse_local_path("Choose target directory", "by-path")
finish.click()

View File

@ -118,6 +118,7 @@ def testNewVMMultiConnection(app):
_forward(newvm)
cdrom.click_combo_entry()
lib.utils.check(lambda: "/dev/sr1" not in cdrom.fmt_nodes())
app.rawinput.pressKey("Escape")
newvm.find_fuzzy("install-iso-browse", "button").click()
browsewin = app.root.find("vmm-storage-browser")
lib.utils.check(lambda: "pool-logical" not in browsewin.fmt_nodes())

View File

@ -101,7 +101,7 @@ def testHostStorageEdit(app):
lib.utils.check(lambda: poolloc.text == newpath)
# Rename it
win.find("default", "table cell").click()
win.find("pool-dir", "table cell").click()
win.find("pool-name").set_text("newsort-default")
finish.click()