File 068-uitests-cover-USB-startup-policy.patch of Package virt-manager
Subject: uitests: cover USB startup policy
From: Cole Robinson crobinso@redhat.com Mon Feb 9 10:25:08 2026 -0500
Date: Mon Feb 9 20:56:38 2026 +0100:
Git: 98921c4dcf0ba218e0d5acc2e31eb24cb3735d54
Signed-off-by: Cole Robinson <crobinso@redhat.com>
diff --git a/tests/uitests/test_addhardware.py b/tests/uitests/test_addhardware.py
index 883ed5415..48a62411c 100644
--- a/tests/uitests/test_addhardware.py
+++ b/tests/uitests/test_addhardware.py
@@ -451,6 +451,7 @@ def testAddHosts(app):
_open_addhw(app, details)
tab = _select_hw(addhw, "USB Host Device", "host-tab")
tab.find_fuzzy("Cruzer Micro 256", "table cell").click()
+ tab.combo_select("Startup Policy:", "optional")
_finish(addhw, check=details)
# Add PCI device
diff --git a/tests/uitests/test_details.py b/tests/uitests/test_details.py
index 097dcff15..19c090b40 100644
--- a/tests/uitests/test_details.py
+++ b/tests/uitests/test_details.py
@@ -568,12 +568,18 @@ def testDetailsEditDevices1(app):
app.click_alert_button("Are you sure", "Yes")
lib.utils.check(lambda: cell.text != oldtext)
- # Host device
+ # Host PCI device
tab = _select_hw(app, win, "PCI 0000:00:19.0", "host-tab")
tab.find("ROM BAR:", "check box").click()
appl.click()
lib.utils.check(lambda: not appl.sensitive)
+ # Host USB device
+ tab = _select_hw(app, win, "USB 003:002", "host-tab")
+ tab.combo_select("Startup Policy:", "requisite")
+ appl.click()
+ lib.utils.check(lambda: not appl.sensitive)
+
# Video device
tab = _select_hw(app, win, "Video VMVGA", "video-tab")
tab.find("Model:", "text").set_text("virtio")