uitests: More workaround for newvm wizard focus grab issues

Signed-off-by: Cole Robinson <crobinso@redhat.com>
This commit is contained in:
Cole Robinson 2020-09-20 17:25:39 -04:00
parent 295c8a86dd
commit 05174f3719
1 changed files with 6 additions and 3 deletions

View File

@ -60,10 +60,9 @@ def testNewVMMultiConnection(app):
"""
manager = app.topwin
def _add_conn(uri):
return app.manager_createconn(uri)
# Check the dialog shows 'no connection' error
app.sleep(1) # give some time for the connection to connect
manager.grab_focus()
app.manager_conn_disconnect("test testdriver.xml")
newvm = _open_newvm(app)
newvm.find_fuzzy("No active connection to install on")
@ -75,6 +74,9 @@ def testNewVMMultiConnection(app):
capsdir = tests.utils.DATADIR + "/capabilities/"
return ",caps=" + capsdir + fname
def _add_conn(uri):
return app.manager_createconn(uri)
# Test empty qemu connection
_add_conn(tests.utils.URIs.kvm + _capsopt("test-empty.xml"))
newvm = _open_newvm(app)
@ -1191,6 +1193,7 @@ def testNewVMSession(app):
manager = app.topwin
manager.window_maximize()
newvm = _open_newvm(app)
app.sleep(.5) # newvm focus grab avoidance
manager.grab_focus()
app.manager_conn_disconnect(".*session.*")
lib.utils.check(lambda: not newvm.showing)