[at-spi2-core: 1/2] fixture teardown: Wait for the a11y bus launcher to really die




commit fabdde4fb7effcc51c0898d1d10a8dacf0bfa1b1
Author: Federico Mena Quintero <federico gnome org>
Date:   Wed Jul 13 13:59:45 2022 -0500

    fixture teardown: Wait for the a11y bus launcher to really die
    
    I think the failed CI jobs are due to at-spi-bus-launcher taking an
    unspecified amount of time to die after the Logout call.  So, let's
    wait for it.

 tests/registryd/conftest.py | 9 +++++++++
 1 file changed, 9 insertions(+)
---
diff --git a/tests/registryd/conftest.py b/tests/registryd/conftest.py
index a80af69f..63ff3086 100644
--- a/tests/registryd/conftest.py
+++ b/tests/registryd/conftest.py
@@ -66,6 +66,15 @@ def session_manager():
     # Reset mock session back to its starting state
     mock_session.Reset(dbus_interface='org.freedesktop.DBus.Mock')
 
+    # Wait a bit for the a11y bus launcher to really die
+    proxy = bus.get_object('org.freedesktop.DBus', '/org/freedesktop/DBus')
+    while True:
+        names = proxy.ListNames(dbus_interface='org.freedesktop.DBus')
+        if 'org.a11y.Bus' in names:
+            time.sleep(1)
+        else:
+            break
+
 @pytest.fixture
 def registry(main_loop, session_manager):
     a11y_address = get_accesssibility_bus_address()


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]