tests: Add a couple of virt-xml memballoon tests

We're going to slightly change how the device is handled in
a minute, and we want to make sure we don't break existing
functionality while doing so.

Note that the existing singleton-config-* test cases already
provide coverage for both enabling and disabling the memory
balloon in virt-install.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
This commit is contained in:
Andrea Bolognani 2019-06-13 12:55:07 +02:00 committed by Cole Robinson
parent 8c5e0797e5
commit 1502417566
3 changed files with 23 additions and 0 deletions

View File

@ -0,0 +1,11 @@
</redirfilter>
<hub type="usb"/>
<watchdog model="ib700" action="poweroff"/>
- <memballoon model="virtio"/>
+ <memballoon model="none"/>
<rng model="virtio">
<rate bytes="1234" period="2000"/>
<backend model="egd" type="tcp">
Domain 'test-for-virtxml' defined successfully.
Changes will take effect after the domain is fully powered off.

View File

@ -0,0 +1,10 @@
</redirfilter>
<hub type="usb"/>
<watchdog model="ib700" action="poweroff"/>
- <memballoon model="virtio"/>
<rng model="virtio">
<rate bytes="1234" period="2000"/>
<backend model="egd" type="tcp">
Domain 'test-for-virtxml' defined successfully.
Changes will take effect after the domain is fully powered off.

View File

@ -1185,6 +1185,7 @@ c.add_compare("--edit /tmp/foobar2 --disk shareable=off,readonly=on", "edit-sele
c.add_compare("--edit mac=00:11:7f:33:44:55 --network target=nic55", "edit-select-network-mac")
c.add_compare("--edit target=hda --disk boot_order=1", "edit-select-disk-bootorder")
c.add_compare("--edit path=/dev/null --disk path=,target=fdb,boot_order=12", "edit-disk-unset") # --disk matching, using empty value to unset path
c.add_compare("--edit --memballoon none", "edit-disable-memballoon")
c = vixml.add_category("edit and start selection", "test-state-shutoff --print-diff --start")
c.add_compare("--define --edit target=vda --disk boot_order=1", "start-select-disk-bootorder")
@ -1218,6 +1219,7 @@ c.add_compare("--remove-device --disk 3", "remove-disk-index")
c.add_compare("--remove-device --disk /dev/null", "remove-disk-path")
c.add_compare("--remove-device --video all", "remove-video-all")
c.add_compare("--remove-device --host-device 0x04b3:0x4485", "remove-hostdev-name")
c.add_compare("--remove-device --memballoon all", "remove-memballoon")
c = vixml.add_category("add/rm devices and start", "test-state-shutoff --print-diff --start")
c.add_invalid("--add-device --pm suspend_to_disk=yes") # --add-device without a device