mirror of
https://github.com/virt-manager/virt-manager.git
synced 2025-01-10 01:18:03 +03:00
tests: add more test cases to cover all code paths
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
This commit is contained in:
parent
74fd503b9e
commit
67206a858a
@ -0,0 +1,83 @@
|
||||
<domain type="kvm">
|
||||
<name>win11</name>
|
||||
<uuid>00000000-1111-2222-3333-444444444444</uuid>
|
||||
<metadata>
|
||||
<libosinfo:libosinfo xmlns:libosinfo="http://libosinfo.org/xmlns/libvirt/domain/1.0">
|
||||
<libosinfo:os id="http://microsoft.com/win/11"/>
|
||||
</libosinfo:libosinfo>
|
||||
</metadata>
|
||||
<memory>65536</memory>
|
||||
<currentMemory>65536</currentMemory>
|
||||
<vcpu>4</vcpu>
|
||||
<os firmware="efi">
|
||||
<type arch="x86_64" machine="q35">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/>
|
||||
<apic/>
|
||||
<hyperv>
|
||||
<vpindex state="off"/>
|
||||
<relaxed state="on"/>
|
||||
<vapic state="on"/>
|
||||
<spinlocks state="on" retries="8191"/>
|
||||
<runtime state="on"/>
|
||||
<frequencies state="on"/>
|
||||
<evmcs state="on"/>
|
||||
<avic state="on"/>
|
||||
</hyperv>
|
||||
<vmport state="off"/>
|
||||
</features>
|
||||
<cpu mode="host-passthrough"/>
|
||||
<clock offset="localtime">
|
||||
<timer name="rtc" tickpolicy="catchup"/>
|
||||
<timer name="pit" tickpolicy="delay"/>
|
||||
<timer name="hpet" present="no"/>
|
||||
<timer name="hypervclock" present="yes"/>
|
||||
</clock>
|
||||
<pm>
|
||||
<suspend-to-mem enabled="no"/>
|
||||
<suspend-to-disk enabled="no"/>
|
||||
</pm>
|
||||
<devices>
|
||||
<emulator>/usr/bin/qemu-system-x86_64</emulator>
|
||||
<controller type="usb" model="qemu-xhci" ports="15"/>
|
||||
<controller type="pci" model="pcie-root"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<interface type="bridge">
|
||||
<source bridge="testsuitebr0"/>
|
||||
<mac address="00:11:22:33:44:55"/>
|
||||
<model type="e1000e"/>
|
||||
</interface>
|
||||
<console type="pty"/>
|
||||
<channel type="spicevmc">
|
||||
<target type="virtio" name="com.redhat.spice.0"/>
|
||||
</channel>
|
||||
<input type="tablet" bus="usb"/>
|
||||
<tpm model="tpm-crb">
|
||||
<backend type="emulator"/>
|
||||
</tpm>
|
||||
<graphics type="spice" port="-1" tlsPort="-1" autoport="yes">
|
||||
<image compression="off"/>
|
||||
</graphics>
|
||||
<sound model="ich9"/>
|
||||
<video>
|
||||
<model type="qxl"/>
|
||||
</video>
|
||||
<redirdev bus="usb" type="spicevmc"/>
|
||||
<redirdev bus="usb" type="spicevmc"/>
|
||||
</devices>
|
||||
</domain>
|
72
tests/data/cli/compare/virt-install-hyperv_no_domcaps.xml
Normal file
72
tests/data/cli/compare/virt-install-hyperv_no_domcaps.xml
Normal file
@ -0,0 +1,72 @@
|
||||
<domain type="kvm">
|
||||
<name>win11</name>
|
||||
<uuid>00000000-1111-2222-3333-444444444444</uuid>
|
||||
<metadata>
|
||||
<libosinfo:libosinfo xmlns:libosinfo="http://libosinfo.org/xmlns/libvirt/domain/1.0">
|
||||
<libosinfo:os id="http://microsoft.com/win/11"/>
|
||||
</libosinfo:libosinfo>
|
||||
</metadata>
|
||||
<memory>65536</memory>
|
||||
<currentMemory>65536</currentMemory>
|
||||
<vcpu>4</vcpu>
|
||||
<os>
|
||||
<type arch="x86_64" machine="q35">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/>
|
||||
<apic/>
|
||||
<vmport state="off"/>
|
||||
</features>
|
||||
<cpu mode="custom" match="exact">
|
||||
<model>Skylake-Client-noTSX-IBRS</model>
|
||||
</cpu>
|
||||
<clock offset="localtime">
|
||||
<timer name="rtc" tickpolicy="catchup"/>
|
||||
<timer name="pit" tickpolicy="delay"/>
|
||||
<timer name="hpet" present="no"/>
|
||||
<timer name="hypervclock" present="yes"/>
|
||||
</clock>
|
||||
<pm>
|
||||
<suspend-to-mem enabled="no"/>
|
||||
<suspend-to-disk enabled="no"/>
|
||||
</pm>
|
||||
<devices>
|
||||
<emulator>/usr/bin/qemu-system-x86_64</emulator>
|
||||
<controller type="usb" model="qemu-xhci" ports="15"/>
|
||||
<controller type="pci" model="pcie-root"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<controller type="pci" model="pcie-root-port"/>
|
||||
<interface type="bridge">
|
||||
<source bridge="testsuitebr0"/>
|
||||
<mac address="00:11:22:33:44:55"/>
|
||||
<model type="e1000e"/>
|
||||
</interface>
|
||||
<console type="pty"/>
|
||||
<channel type="spicevmc">
|
||||
<target type="virtio" name="com.redhat.spice.0"/>
|
||||
</channel>
|
||||
<input type="tablet" bus="usb"/>
|
||||
<graphics type="spice" port="-1" tlsPort="-1" autoport="yes">
|
||||
<image compression="off"/>
|
||||
</graphics>
|
||||
<sound model="ich9"/>
|
||||
<video>
|
||||
<model type="qxl"/>
|
||||
</video>
|
||||
<redirdev bus="usb" type="spicevmc"/>
|
||||
<redirdev bus="usb" type="spicevmc"/>
|
||||
</devices>
|
||||
</domain>
|
@ -72,6 +72,7 @@ TEST_DATA = {
|
||||
'URI-TEST-FULL': utils.URIs.test_full,
|
||||
'URI-TEST-REMOTE': utils.URIs.test_remote,
|
||||
'URI-KVM-X86': utils.URIs.kvm_x86,
|
||||
'URI-KVM-X86-NODOMCAPS': utils.URIs.kvm_x86_nodomcaps,
|
||||
'URI-KVM-ARMV7L': utils.URIs.kvm_armv7l,
|
||||
'URI-KVM-AARCH64': utils.URIs.kvm_aarch64,
|
||||
'URI-KVM-LOONGARCH64': utils.URIs.kvm_loongarch64,
|
||||
@ -1356,6 +1357,10 @@ c.add_valid("--connect %(URI-KVM-X86)s --install fedora28 --cloud-init", grep="P
|
||||
c.add_invalid("--pxe --autoconsole badval", grep="Unknown autoconsole type 'badval'")
|
||||
c.add_invalid("--pxe --autoconsole text --wait -1", grep="exceeded specified time limit") # hits a specific code path where we skip console waitpid
|
||||
|
||||
c = vinst.add_category("hyperv", "--disk none --osinfo win11 --import")
|
||||
c.add_compare("--connect %(URI-KVM-X86)s --features hyperv.vpindex.state=off", "hyperv_disable_vpindex") # disable feature that is required by others to test they are not enabled by default
|
||||
c.add_compare("--connect %(URI-KVM-X86-NODOMCAPS)s", "hyperv_no_domcaps") # don't use domain capabilities to enable only some features by version check
|
||||
|
||||
|
||||
##################
|
||||
# virt-xml tests #
|
||||
|
Loading…
Reference in New Issue
Block a user