tests: uitests: Fix remote dbus test
My last patch broke it!
This commit is contained in:
parent
40461c58ef
commit
10290cbf48
|
@ -65,7 +65,7 @@ class VMMCLI(uiutils.UITestCase):
|
|||
"""
|
||||
self.app.open()
|
||||
newapp = uiutils.VMMDogtailApp("test:///default")
|
||||
newapp.open()
|
||||
newapp.open(check_already_running=False)
|
||||
uiutils.check_in_loop(lambda: not newapp.is_running())
|
||||
import dogtail.tree
|
||||
vapps = [a for a in dogtail.tree.root.applications() if
|
||||
|
|
|
@ -355,7 +355,7 @@ class VMMDogtailApp(object):
|
|||
def is_running(self):
|
||||
return bool(self._proc and self._proc.poll() is None)
|
||||
|
||||
def open(self, extra_opts=None):
|
||||
def open(self, extra_opts=None, check_already_running=True):
|
||||
extra_opts = extra_opts or []
|
||||
|
||||
if tests.utils.clistate.debug:
|
||||
|
@ -374,7 +374,8 @@ class VMMDogtailApp(object):
|
|||
"--test-first-run", "--no-fork", "--connect", self.uri]
|
||||
cmd += extra_opts
|
||||
|
||||
self.error_if_already_running()
|
||||
if check_already_running:
|
||||
self.error_if_already_running()
|
||||
self._proc = subprocess.Popen(cmd, stdout=stdout, stderr=stderr)
|
||||
self._root = dogtail.tree.root.application("virt-manager")
|
||||
self._topwin = self._root.find(None, "(frame|dialog|alert)")
|
||||
|
|
Loading…
Reference in New Issue