X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fat-spi2-atk.git;a=blobdiff_plain;f=droute%2Fdroute-test.c;h=a2ebe4d70ef0d8063c45ab1061dee4ac14b0627c;hp=8b3fb7c9b838be45cd9a8aae58ea4db15872ef1b;hb=1f7056caa3077253083aa840d79d3c137da9e269;hpb=3caecca1b1e7614828a9aa0e0c378127329fbefd diff --git a/droute/droute-test.c b/droute/droute-test.c index 8b3fb7c..a2ebe4d 100644 --- a/droute/droute-test.c +++ b/droute/droute-test.c @@ -4,7 +4,7 @@ #include #include -#include "dbus/dbus-glib-lowlevel.h" +#include "atspi/atspi.h" #define TEST_OBJECT_PATH "/test/object" #define TEST_INTERFACE_ONE "test.interface.One" @@ -13,10 +13,6 @@ #define OBJECT_ONE "ObjectOne"; #define OBJECT_TWO "ObjectTwo"; -#if !defined TEST_INTROSPECTION_DIRECTORY - #error "No introspection XML directory defined" -#endif - #define STRING_ONE "StringOne" #define STRING_TWO "StringTwo" @@ -25,6 +21,40 @@ #define NONE_REPLY_STRING "NoneMethod" +const gchar *test_interface_One = \ +"" +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +""; + +const gchar *test_interface_Two = \ +"" +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +""; + typedef struct _AnObject { gchar *astring; @@ -219,23 +249,25 @@ int main (int argc, char **argv) dbus_error_init (&error); main_loop = g_main_loop_new(NULL, FALSE); bus = dbus_bus_get (DBUS_BUS_SESSION, &error); - dbus_connection_setup_with_g_main(bus, g_main_context_default()); + atspi_dbus_connection_setup_with_g_main(bus, g_main_context_default()); - cnx = droute_new (bus, TEST_INTROSPECTION_DIRECTORY); + cnx = droute_new (bus); path = droute_add_one (cnx, TEST_OBJECT_PATH, object); droute_path_add_interface (path, TEST_INTERFACE_ONE, + test_interface_One, test_methods_one, test_properties); droute_path_add_interface (path, TEST_INTERFACE_TWO, + test_interface_Two, test_methods_two, test_properties); g_idle_add (do_tests_func, NULL); - g_main_run(main_loop); + g_main_loop_run(main_loop); if (success) return 0; else