summaryrefslogtreecommitdiffstats
path: root/src/tests/sbus_tests.c
diff options
context:
space:
mode:
authorPavel Březina <pbrezina@redhat.com>2014-12-13 14:25:14 +0100
committerJakub Hrozek <jhrozek@redhat.com>2015-01-23 21:29:41 +0100
commit80d0bd38268c02fd32f62b02ae59f19229ca1a79 (patch)
treedaf1d544a9593ecf63999df0899278c80332d7ef /src/tests/sbus_tests.c
parent21e05273eed8cc914871938061554589883e67ce (diff)
downloadsssd-80d0bd38268c02fd32f62b02ae59f19229ca1a79.tar.gz
sssd-80d0bd38268c02fd32f62b02ae59f19229ca1a79.tar.xz
sssd-80d0bd38268c02fd32f62b02ae59f19229ca1a79.zip
sbus: support org.freedesktop.DBus.Introspectable
This commit brings back support of Introspectable interface and enables support of multiple interfaces there. It also refactors the old code so the generator and introspect xml format especially is more readable. Reviewed-by: Jakub Hrozek <jhrozek@redhat.com>
Diffstat (limited to 'src/tests/sbus_tests.c')
-rw-r--r--src/tests/sbus_tests.c37
1 files changed, 11 insertions, 26 deletions
diff --git a/src/tests/sbus_tests.c b/src/tests/sbus_tests.c
index 288163d61..04ec21847 100644
--- a/src/tests/sbus_tests.c
+++ b/src/tests/sbus_tests.c
@@ -46,30 +46,17 @@
#define PILOT_IFACE_INTROSPECT \
"<!DOCTYPE node PUBLIC \"-//freedesktop//DTD D-BUS Object Introspection 1.0//EN\"\n" \
- "\"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd\">\n" \
- "<node>\n" \
- " <interface name=\"test.Pilot\">\n" \
- " <method name=\"Blink\">\n" \
- " </method>\n" \
- " <method name=\"Eat\">\n" \
- " </method>\n" \
- " </interface>\n" \
- " <interface name=\"org.freedesktop.DBus.Introspectable\">\n" \
- " <method name=\"Introspect\">\n" \
- " <arg name=\"data\" type=\"s\" direction=\"out\"/>\n" \
- " </method>\n" \
- " </interface>\n" \
- " <interface name=\"org.freedesktop.DBus.Properties\">\n" \
- " <method name=\"Get\">\n" \
- " <arg name=\"interface\" direction=\"in\" type=\"s\"/>\n" \
- " <arg name=\"property\" direction=\"in\" type=\"s\"/>\n" \
- " <arg name=\"value\" direction=\"out\" type=\"v\"/>\n" \
- " </method>\n" \
- " <method name=\"GetAll\">\n" \
- " <arg name=\"interface\" direction=\"in\" type=\"s\"/>\n" \
- " <arg name=\"properties\" direction=\"out\" type=\"a{sv}\"/>\n" \
- " </method>\n" \
- " </interface>\n" \
+ " \"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd\">\n" \
+ "<node>\n" \
+ " <interface name=\"org.freedesktop.DBus.Introspectable\">\n" \
+ " <method name=\"Introspect\">\n" \
+ " <arg type=\"s\" name=\"data\" direction=\"out\" />\n" \
+ " </method>\n" \
+ " </interface>\n" \
+ " <interface name=\"test.Pilot\">\n" \
+ " <method name=\"Blink\" />\n" \
+ " <method name=\"Eat\" />\n" \
+ " </interface>\n" \
"</node>\n"
/* our vtable */
@@ -370,9 +357,7 @@ TCase *create_sbus_tests(void)
tcase_add_test(tc, test_raw_handler);
tcase_add_test(tc, test_request_parse_ok);
tcase_add_test(tc, test_request_parse_bad_args);
-#if false
tcase_add_test(tc, test_introspection);
-#endif
tcase_add_test(tc, test_sbus_new_error);
return tc;