diff options
-rw-r--r-- | registryd/registry.c | 1 | ||||
-rw-r--r-- | tests/registryd/test_root_introspectable.py | 20 |
2 files changed, 21 insertions, 0 deletions
diff --git a/registryd/registry.c b/registryd/registry.c index e17fe149..8ca291f9 100644 --- a/registryd/registry.c +++ b/registryd/registry.c @@ -1065,6 +1065,7 @@ impl_Introspect_root (DBusMessage * message, SpiRegistry *registry) g_string_append (output, spi_org_a11y_atspi_Accessible); g_string_append (output, spi_org_a11y_atspi_Component); + g_string_append (output, spi_org_a11y_atspi_Socket); g_string_append(output, introspection_footer); final = g_string_free(output, FALSE); diff --git a/tests/registryd/test_root_introspectable.py b/tests/registryd/test_root_introspectable.py new file mode 100644 index 00000000..64845630 --- /dev/null +++ b/tests/registryd/test_root_introspectable.py @@ -0,0 +1,20 @@ +import pytest +import dbus +import xml.etree.ElementTree as ElementTree + +INTROSPECTABLE_IFACE = 'org.freedesktop.DBus.Introspectable' + +def test_introspect(registry_root, session_manager): + xml_str = str(registry_root.Introspect(dbus_interface=INTROSPECTABLE_IFACE)) + root = ElementTree.fromstring(xml_str) + assert root.tag == 'node' + + interface_elements = root.findall('./interface') + iface_names = map(lambda e: e.attrib['name'], interface_elements) + iface_names = list(iface_names) + iface_names.sort() + + assert iface_names == ['org.a11y.atspi.Accessible', + 'org.a11y.atspi.Component', + 'org.a11y.atspi.Socket', + ] |