Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Backports:SLE-15-SP4:RebuildFactoryCandidates
virt-manager
094-uitests-handle-newer-libvirt-test-driver-Up...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 094-uitests-handle-newer-libvirt-test-driver-UpdateDevice-support.patch of Package virt-manager
Subject: uitests: handle newer libvirt test driver UpdateDevice support From: Cole Robinson crobinso@redhat.com Wed Aug 7 14:24:33 2024 -0400 Date: Mon Aug 12 19:55:58 2024 -0400: Git: a00c090022dda9019c38c1f86ca3f7274ae63b43 Make it fail for the cases that expect it Signed-off-by: Cole Robinson <crobinso@redhat.com> --- a/tests/uitests/test_details.py +++ b/tests/uitests/test_details.py @@ -672,6 +672,7 @@ def testDetailsMiscEdits(app): Test misc editing behavior, like checking for unapplied changes """ + app.open(extra_opts=["--test-options=test-update-device-fail"]) win = app.manager_open_details("test-many-devices") hwlist = win.find("hw-list") --- a/tests/uitests/test_mediachange.py +++ b/tests/uitests/test_mediachange.py @@ -86,7 +86,8 @@ def testMediaHotplug(app): Test in the case of a running VM """ vmname = "test-many-devices" - app.open(show_console=vmname) + app.open(show_console=vmname, + extra_opts=["--test-options=test-update-device-fail"]) win = app.find_details_window(vmname, click_details=True) hw = win.find("hw-list") entry = win.find("media-entry") --- a/virtManager/lib/testmock.py +++ b/virtManager/lib/testmock.py @@ -163,6 +163,7 @@ class CLITestOptionsClass: managed save issues * test-vm-run-fail: Make VM run fail, so we can test the error path + * test-update-device-fail: Make UpdateDevice API call fail * spice-agent: Make spice-agent detection return true in viewer.py @@ -219,6 +220,7 @@ class CLITestOptionsClass: self.enable_libguestfs = _get("enable-libguestfs") self.test_managed_save = _get("test-managed-save") self.test_vm_run_fail = _get("test-vm-run-fail") + self.test_update_device_fail = _get("test-update-device-fail") self.spice_agent = _get("spice-agent") self.firstrun_uri = _get_value("firstrun-uri") self.fake_vnc_username = _get("fake-vnc-username") --- a/virtManager/object/domain.py +++ b/virtManager/object/domain.py @@ -1083,6 +1083,9 @@ class vmmDomain(vmmLibvirtObject): xml = devobj.get_xml() log.debug("update_device with xml=\n%s", xml) + + if self.config.CLITestOptions.test_update_device_fail: + raise RuntimeError("fake update device failure") self._backend.updateDeviceFlags(xml, flags) def hotplug(self, memory=_SENTINEL, maxmem=_SENTINEL,
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor