summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtest/test-dbus.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/test/test-dbus.py b/test/test-dbus.py
index 076e8997..a98e186e 100755
--- a/test/test-dbus.py
+++ b/test/test-dbus.py
@@ -2790,8 +2790,11 @@ class TestSessionAPIsDummy(DBusUtil, unittest.TestCase):
# dbus server will be blocked by gnome-keyring-ask dialog, so we kill it, and then
# it can't get the password from gnome keyring and send info request for password
def callback():
- kill = subprocess.Popen("sh -c 'killall -9 gnome-keyring-ask >/dev/null 2>&1'", shell=True)
- kill.communicate()
+ kill = subprocess.Popen('killall -9 gnome-keyring-ask'.split(),
+ stdout=open('/dev/null', 'w'),
+ stderr=subprocess.STDOUT)
+ kill.wait()
+ # Kill again soon.
return True
timeout_handler = Timeout.addTimeout(1, callback)