summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelipe Magno de Almeida <felipe@expertisesolutions.com.br>2015-09-25 13:15:49 -0700
committerFelipe Magno de Almeida <felipe@expertisesolutions.com.br>2015-09-25 13:15:49 -0700
commit462ecf69d368466a20cba60a593bf695b422e9bc (patch)
treed8554bcd0e9c5a669fe6662711fc84ed89df03c2
parent7457f37df48c0eb9cfcdf012d863d1a995db6264 (diff)
Fixed connection_model_set on object.
-rw-r--r--src/lib/eldbus/eldbus_model_connection.c21
-rw-r--r--src/lib/eldbus/eldbus_model_object.c120
-rw-r--r--src/lib/eldbus/eldbus_model_object.eo54
-rw-r--r--src/lib/eldbus/eldbus_model_object_private.h6
-rw-r--r--src/lib/eldbus/eldbus_model_proxy.c2
-rw-r--r--src/lib/eldbus/eldbus_model_signal.eo12
-rw-r--r--src/tests/eldbus/eldbus_test_eldbus_model.c16
-rw-r--r--src/tests/eldbus/eldbus_test_eldbus_model_method.c16
-rw-r--r--src/tests/eldbus/eldbus_test_eldbus_model_signal.c16
-rw-r--r--src/tests/eldbus/eldbus_test_fake_server_eldbus_model_proxy.c16
10 files changed, 113 insertions, 166 deletions
diff --git a/src/lib/eldbus/eldbus_model_connection.c b/src/lib/eldbus/eldbus_model_connection.c
index d7919380de..4ac97e2d55 100644
--- a/src/lib/eldbus/eldbus_model_connection.c
+++ b/src/lib/eldbus/eldbus_model_connection.c
@@ -37,20 +37,6 @@ _eldbus_model_connection_eo_base_constructor(Eo *obj, Eldbus_Model_Connection_Da
37 return obj; 37 return obj;
38} 38}
39 39
40/* static void */
41/* _eldbus_model_connection_constructor(Eo *obj EINA_UNUSED, */
42/* Eldbus_Model_Connection_Data *pd, */
43/* int type, */
44/* const char* address, */
45/* Eina_Bool private) */
46/* { */
47/* DBG("(%p)", obj); */
48
49/* pd->type = type; */
50/* pd->address = eina_stringshare_add(address); */
51/* pd->private = private; */
52/* } */
53
54static void 40static void
55_eldbus_model_connection_eo_base_destructor(Eo *obj, Eldbus_Model_Connection_Data *pd) 41_eldbus_model_connection_eo_base_destructor(Eo *obj, Eldbus_Model_Connection_Data *pd)
56{ 42{
@@ -269,6 +255,9 @@ _eldbus_model_connection_type_set(Eo *obj EINA_UNUSED, Eldbus_Model_Connection_D
269static void 255static void
270_eldbus_model_connection_connect(Eldbus_Model_Connection_Data *pd) 256_eldbus_model_connection_connect(Eldbus_Model_Connection_Data *pd)
271{ 257{
258 fprintf(stderr, "connecting\n");
259 fflush(stderr);
260
272 EINA_SAFETY_ON_NULL_RETURN(pd); 261 EINA_SAFETY_ON_NULL_RETURN(pd);
273 262
274 if (ELDBUS_CONNECTION_TYPE_ADDRESS == pd->type) 263 if (ELDBUS_CONNECTION_TYPE_ADDRESS == pd->type)
@@ -357,7 +346,9 @@ _eldbus_model_connection_names_list_cb(void *data,
357 DBG("(%p): bus = %s", pd->obj, bus); 346 DBG("(%p): bus = %s", pd->obj, bus);
358 347
359 Eo *child = eo_add(ELDBUS_MODEL_OBJECT_CLASS, NULL, 348 Eo *child = eo_add(ELDBUS_MODEL_OBJECT_CLASS, NULL,
360 eldbus_model_object_connection_constructor(pd->connection, bus, "/")); 349 eldbus_model_object_connection_set(pd->connection),
350 eldbus_model_object_bus_set(bus),
351 eldbus_model_object_path_set("/"));
361 352
362 pd->children_list = eina_list_append(pd->children_list, child); 353 pd->children_list = eina_list_append(pd->children_list, child);
363 } 354 }
diff --git a/src/lib/eldbus/eldbus_model_object.c b/src/lib/eldbus/eldbus_model_object.c
index 3be4638fcc..17a8fe5c91 100644
--- a/src/lib/eldbus/eldbus_model_object.c
+++ b/src/lib/eldbus/eldbus_model_object.c
@@ -4,6 +4,7 @@
4 4
5#include "eldbus_model_object_private.h" 5#include "eldbus_model_object_private.h"
6#include "eldbus_model_private.h" 6#include "eldbus_model_private.h"
7#include "eldbus_model_connection_private.h"
7 8
8#include <Eina.h> 9#include <Eina.h>
9 10
@@ -35,9 +36,6 @@ _eldbus_model_object_eo_base_constructor(Eo *obj, Eldbus_Model_Object_Data *pd)
35 pd->object_list = NULL; 36 pd->object_list = NULL;
36 pd->properties_array = NULL; 37 pd->properties_array = NULL;
37 pd->children_list = NULL; 38 pd->children_list = NULL;
38 pd->type = ELDBUS_CONNECTION_TYPE_UNKNOWN;
39 pd->address = NULL;
40 pd->private = false;
41 pd->bus = NULL; 39 pd->bus = NULL;
42 pd->path = NULL; 40 pd->path = NULL;
43 pd->unique_name = NULL; 41 pd->unique_name = NULL;
@@ -48,40 +46,40 @@ _eldbus_model_object_eo_base_constructor(Eo *obj, Eldbus_Model_Object_Data *pd)
48} 46}
49 47
50static void 48static void
51_eldbus_model_object_constructor(Eo *obj EINA_UNUSED, 49_eldbus_model_object_connection_set(Eo *obj EINA_UNUSED,
52 Eldbus_Model_Object_Data *pd, 50 Eldbus_Model_Object_Data *pd,
53 int type, 51 Eldbus_Connection *connection)
54 const char* address,
55 Eina_Bool private,
56 const char* bus,
57 const char* path)
58{ 52{
59 DBG("(%p)", obj); 53 DBG("(%p)", obj);
60 EINA_SAFETY_ON_NULL_RETURN(bus); 54 EINA_SAFETY_ON_NULL_RETURN(connection);
61 EINA_SAFETY_ON_NULL_RETURN(path); 55
62 56 pd->connection = eldbus_connection_ref(connection);
63 pd->type = type; 57}
64 pd->address = eina_stringshare_add(address); 58
65 pd->private = private; 59static Eldbus_Connection*
66 pd->bus = eina_stringshare_add(bus); 60_eldbus_model_object_connection_get(Eo *obj EINA_UNUSED,
67 pd->path = eina_stringshare_add(path); 61 Eldbus_Model_Object_Data *pd)
62{
63 DBG("(%p)", obj);
64
65 return pd->connection;
68} 66}
69 67
70static void 68static void
71_eldbus_model_object_connection_constructor(Eo *obj EINA_UNUSED, 69_eldbus_model_object_connection_model_set(Eo *obj EINA_UNUSED,
72 Eldbus_Model_Object_Data *pd, 70 Eldbus_Model_Object_Data *pd,
73 Eldbus_Connection *connection, 71 Eldbus_Model_Connection *connection)
74 const char* bus,
75 const char* path)
76{ 72{
77 DBG("(%p)", obj); 73 DBG("(%p)", obj);
78 EINA_SAFETY_ON_NULL_RETURN(connection); 74 EINA_SAFETY_ON_NULL_RETURN(connection);
79 EINA_SAFETY_ON_NULL_RETURN(bus);
80 EINA_SAFETY_ON_NULL_RETURN(path);
81 75
82 pd->connection = eldbus_connection_ref(connection); 76 Eldbus_Model_Connection_Data* connection_data
83 pd->bus = eina_stringshare_add(bus); 77 = eo_data_scope_get(connection, ELDBUS_MODEL_CONNECTION_CLASS);
84 pd->path = eina_stringshare_add(path); 78 eo_do(connection, fprintf(stderr, "%d\n", eldbus_model_connection_type_get()));
79 fflush(stderr);
80 pd->connection = eldbus_connection_ref(connection_data->connection);
81
82 EINA_SAFETY_ON_FALSE_RETURN(NULL != pd->connection);
85} 83}
86 84
87static void 85static void
@@ -89,7 +87,6 @@ _eldbus_model_object_eo_base_destructor(Eo *obj, Eldbus_Model_Object_Data *pd)
89{ 87{
90 DBG("(%p)", obj); 88 DBG("(%p)", obj);
91 89
92 eina_stringshare_del(pd->address);
93 eina_stringshare_del(pd->bus); 90 eina_stringshare_del(pd->bus);
94 eina_stringshare_del(pd->path); 91 eina_stringshare_del(pd->path);
95 92
@@ -271,43 +268,6 @@ _eldbus_model_object_efl_model_base_children_load(Eo *obj, Eldbus_Model_Object_D
271} 268}
272 269
273static const char * 270static const char *
274_eldbus_model_object_address_get(Eo *obj EINA_UNUSED, Eldbus_Model_Object_Data *pd)
275{
276 return pd->address;
277}
278
279static void
280_eldbus_model_object_address_set(Eo *obj EINA_UNUSED, Eldbus_Model_Object_Data *pd, const char *value)
281{
282 eina_stringshare_del(pd->address);
283 pd->address = eina_stringshare_add(value);
284}
285
286static Eina_Bool
287_eldbus_model_object_private_get(Eo *obj EINA_UNUSED, Eldbus_Model_Object_Data *pd)
288{
289 return pd->private;
290}
291
292static void
293_eldbus_model_object_private_set(Eo *obj EINA_UNUSED, Eldbus_Model_Object_Data *pd, Eina_Bool value)
294{
295 pd->private = value;
296}
297
298static int
299_eldbus_model_object_type_get(Eo *obj EINA_UNUSED, Eldbus_Model_Object_Data *pd)
300{
301 return pd->type;
302}
303
304static void
305_eldbus_model_object_type_set(Eo *obj EINA_UNUSED, Eldbus_Model_Object_Data *pd, int value)
306{
307 pd->type = value;
308}
309
310static const char *
311_eldbus_model_object_bus_get(Eo *obj EINA_UNUSED, Eldbus_Model_Object_Data *pd) 271_eldbus_model_object_bus_get(Eo *obj EINA_UNUSED, Eldbus_Model_Object_Data *pd)
312{ 272{
313 return pd->bus; 273 return pd->bus;
@@ -338,20 +298,20 @@ _eldbus_model_object_connect(Eldbus_Model_Object_Data *pd)
338{ 298{
339 EINA_SAFETY_ON_NULL_RETURN(pd); 299 EINA_SAFETY_ON_NULL_RETURN(pd);
340 300
341 if (ELDBUS_CONNECTION_TYPE_ADDRESS == pd->type) 301 /* if (ELDBUS_CONNECTION_TYPE_ADDRESS == pd->type) */
342 { 302 /* { */
343 if (pd->private) 303 /* if (pd->private) */
344 pd->connection = eldbus_address_connection_get(pd->address); 304 /* pd->connection = eldbus_address_connection_get(pd->address); */
345 else 305 /* else */
346 pd->connection = eldbus_private_address_connection_get(pd->address); 306 /* pd->connection = eldbus_private_address_connection_get(pd->address); */
347 } 307 /* } */
348 else 308 /* else */
349 { 309 /* { */
350 if (pd->private) 310 /* if (pd->private) */
351 pd->connection = eldbus_private_connection_get(pd->type); 311 /* pd->connection = eldbus_private_connection_get(pd->type); */
352 else 312 /* else */
353 pd->connection = eldbus_connection_get(pd->type); 313 /* pd->connection = eldbus_connection_get(pd->type); */
354 } 314 /* } */
355 315
356 // TODO: Register for disconnection event 316 // TODO: Register for disconnection event
357 317
diff --git a/src/lib/eldbus/eldbus_model_object.eo b/src/lib/eldbus/eldbus_model_object.eo
index 68cbc81d0f..75b45898e7 100644
--- a/src/lib/eldbus/eldbus_model_object.eo
+++ b/src/lib/eldbus/eldbus_model_object.eo
@@ -2,51 +2,31 @@ class Eldbus.Model_Object (Eo.Base, Efl.Model.Base) {
2 legacy_prefix: null; 2 legacy_prefix: null;
3 data: Eldbus_Model_Object_Data; 3 data: Eldbus_Model_Object_Data;
4 methods { 4 methods {
5 constructor { 5 @property bus {
6 [[Custom Eldbus_Model_Object constructor. 6 set {}
7 7 get {}
8 @since 1.16]]
9 params {
10 @in type: int; [[The connection type]]
11 @in address: const(char)*; [[Remote address of dbus]]
12 @in private_: bool; [[Non shared dbus connection]]
13 @in bus: const(char)*; [[DBus Name or unique-id]]
14 @in path: const(char)*; [[DBus path]]
15 }
16 }
17 connection_constructor {
18 [[Custom Eldbus_Model_Object connection_constructor.
19
20 @since 1.16]]
21 params {
22 @in connection: Eldbus_Connection*; [[Eldbus connection]]
23 @in bus: const(char)*; [[DBus Name or unique-id]]
24 @in path: const(char)*; [[DBus path]]
25 }
26 }
27 @property type {
28 values {
29 value: int;
30 }
31 }
32 @property address {
33 values { 8 values {
34 value: const(char)*; 9 value: const(char)*;
35 } 10 }
36 } 11 }
37 @property private { 12 @property path {
13 set {}
14 get {}
38 values { 15 values {
39 value: bool; 16 value: const(char)*;
40 } 17 }
41 } 18 }
42 @property bus { 19 @property connection_model {
20 set {}
43 values { 21 values {
44 value: const(char)*; 22 value: Eldbus.Model_Connection*;
45 } 23 }
46 } 24 }
47 @property path { 25 @property connection {
26 set {}
27 get {}
48 values { 28 values {
49 value: const(char)*; 29 value: Eldbus_Connection*;
50 } 30 }
51 } 31 }
52 } 32 }
@@ -67,7 +47,9 @@ class Eldbus.Model_Object (Eo.Base, Efl.Model.Base) {
67 Efl.Model.Base.children_load; 47 Efl.Model.Base.children_load;
68 } 48 }
69 constructors { 49 constructors {
70 .constructor; 50 .connection @optional;
71 .connection_constructor; 51 .connection_model @optional;
52 .bus;
53 .path;
72 } 54 }
73} 55}
diff --git a/src/lib/eldbus/eldbus_model_object_private.h b/src/lib/eldbus/eldbus_model_object_private.h
index 745492143e..8a471a7f23 100644
--- a/src/lib/eldbus/eldbus_model_object_private.h
+++ b/src/lib/eldbus/eldbus_model_object_private.h
@@ -18,9 +18,9 @@ struct _Eldbus_Model_Object_Data
18 Eina_List *object_list; 18 Eina_List *object_list;
19 Eina_Array *properties_array; 19 Eina_Array *properties_array;
20 Eina_List *children_list; 20 Eina_List *children_list;
21 Eldbus_Connection_Type type; 21 // Eldbus_Connection_Type type;
22 Eina_Stringshare *address; 22 // Eina_Stringshare *address;
23 bool private; 23 // bool private;
24 Eina_Stringshare *bus; 24 Eina_Stringshare *bus;
25 Eina_Stringshare *path; 25 Eina_Stringshare *path;
26 Eina_Value *unique_name; 26 Eina_Value *unique_name;
diff --git a/src/lib/eldbus/eldbus_model_proxy.c b/src/lib/eldbus/eldbus_model_proxy.c
index b9f175ad1f..cc1b5bba94 100644
--- a/src/lib/eldbus/eldbus_model_proxy.c
+++ b/src/lib/eldbus/eldbus_model_proxy.c
@@ -378,7 +378,7 @@ _eldbus_model_proxy_create_signals_children(Eldbus_Model_Proxy_Data *pd)
378 DBG("(%p) Creating signal child: bus = %s, path = %s, signal = %s::%s", pd->obj, bus, path, interface_name, signal_name); 378 DBG("(%p) Creating signal child: bus = %s, path = %s, signal = %s::%s", pd->obj, bus, path, interface_name, signal_name);
379 379
380 Eo *child = eo_add(ELDBUS_MODEL_SIGNAL_CLASS, NULL, 380 Eo *child = eo_add(ELDBUS_MODEL_SIGNAL_CLASS, NULL,
381 eldbus_model_signal_proxy_set(pd->proxy), 381 eldbus_model_arguments_proxy_set(pd->proxy),
382 eldbus_model_signal_set(signal)); 382 eldbus_model_signal_set(signal));
383 383
384 pd->children_list = eina_list_append(pd->children_list, child); 384 pd->children_list = eina_list_append(pd->children_list, child);
diff --git a/src/lib/eldbus/eldbus_model_signal.eo b/src/lib/eldbus/eldbus_model_signal.eo
index 473c64ec4e..254c9b34f1 100644
--- a/src/lib/eldbus/eldbus_model_signal.eo
+++ b/src/lib/eldbus/eldbus_model_signal.eo
@@ -1,16 +1,6 @@
1class Eldbus.Model_Signal (Eldbus.Model_Arguments) { 1class Eldbus.Model_Signal (Eldbus.Model_Arguments) {
2 legacy_prefix: null; 2 legacy_prefix: null;
3 methods { 3 methods {
4 @property proxy {
5 [[Custom Eldbus_Model_Signal constructor.
6
7 @since 1.16]]
8 set {}
9 get {}
10 values {
11 proxy: Eldbus_Proxy*; [[Eldbus proxy]]
12 }
13 }
14 @property signal { 4 @property signal {
15 set {} 5 set {}
16 get {} 6 get {}
@@ -26,7 +16,7 @@ class Eldbus.Model_Signal (Eldbus.Model_Arguments) {
26 Efl.Model.Base.unload; 16 Efl.Model.Base.unload;
27 } 17 }
28 constructors { 18 constructors {
29 .proxy; 19 Eldbus.Model_Arguments.proxy;
30 .signal; 20 .signal;
31 } 21 }
32} 22}
diff --git a/src/tests/eldbus/eldbus_test_eldbus_model.c b/src/tests/eldbus/eldbus_test_eldbus_model.c
index 2ce2361ff6..cd68e6ec38 100644
--- a/src/tests/eldbus/eldbus_test_eldbus_model.c
+++ b/src/tests/eldbus/eldbus_test_eldbus_model.c
@@ -147,12 +147,18 @@ create_and_load_connection(void)
147Eo * 147Eo *
148create_object(void) 148create_object(void)
149{ 149{
150 Eo *connection = eo_add(ELDBUS_MODEL_CONNECTION_CLASS, NULL,
151 eldbus_model_connection_type_set(ELDBUS_CONNECTION_TYPE_SESSION),
152 eldbus_model_connection_address_set(NULL),
153 eldbus_model_connection_private_set(EINA_FALSE));
154 ck_assert_ptr_ne(NULL, connection);
155
156 efl_model_load_and_wait_for_load_status(connection, EFL_MODEL_LOAD_STATUS_LOADED);
157
150 Eo *object = eo_add_ref(ELDBUS_MODEL_OBJECT_CLASS, NULL, 158 Eo *object = eo_add_ref(ELDBUS_MODEL_OBJECT_CLASS, NULL,
151 eldbus_model_object_constructor(ELDBUS_CONNECTION_TYPE_SESSION, 159 eldbus_model_object_connection_model_set(connection),
152 NULL, 160 eldbus_model_object_bus_set(ELDBUS_FDO_BUS),
153 EINA_FALSE, 161 eldbus_model_object_path_set(ELDBUS_FDO_PATH));
154 ELDBUS_FDO_BUS,
155 ELDBUS_FDO_PATH));
156 ck_assert_ptr_ne(NULL, object); 162 ck_assert_ptr_ne(NULL, object);
157 return object; 163 return object;
158} 164}
diff --git a/src/tests/eldbus/eldbus_test_eldbus_model_method.c b/src/tests/eldbus/eldbus_test_eldbus_model_method.c
index 6c9dc5b008..7a68035e6b 100644
--- a/src/tests/eldbus/eldbus_test_eldbus_model_method.c
+++ b/src/tests/eldbus/eldbus_test_eldbus_model_method.c
@@ -29,12 +29,18 @@ _setup(void)
29 29
30 fake_server = fake_server_start(&fake_server_data); 30 fake_server = fake_server_start(&fake_server_data);
31 31
32 Eldbus_Model_Connection* connection
33 = eo_add(ELDBUS_MODEL_CONNECTION_CLASS, NULL,
34 eldbus_model_connection_type_set(ELDBUS_CONNECTION_TYPE_SESSION),
35 eldbus_model_connection_address_set(NULL),
36 eldbus_model_connection_private_set(EINA_FALSE));
37
38 efl_model_load_and_wait_for_load_status(connection, EFL_MODEL_LOAD_STATUS_LOADED);
39
32 fake_server_object = eo_add(ELDBUS_MODEL_OBJECT_CLASS, NULL, 40 fake_server_object = eo_add(ELDBUS_MODEL_OBJECT_CLASS, NULL,
33 eldbus_model_object_constructor(ELDBUS_CONNECTION_TYPE_SESSION, 41 eldbus_model_object_connection_model_set(connection),
34 NULL, 42 eldbus_model_object_bus_set(FAKE_SERVER_BUS),
35 EINA_FALSE, 43 eldbus_model_object_path_set(FAKE_SERVER_PATH));
36 FAKE_SERVER_BUS,
37 FAKE_SERVER_PATH));
38 ck_assert_ptr_ne(NULL, fake_server_object); 44 ck_assert_ptr_ne(NULL, fake_server_object);
39 45
40 efl_model_load_and_wait_for_load_status(fake_server_object, EFL_MODEL_LOAD_STATUS_LOADED); 46 efl_model_load_and_wait_for_load_status(fake_server_object, EFL_MODEL_LOAD_STATUS_LOADED);
diff --git a/src/tests/eldbus/eldbus_test_eldbus_model_signal.c b/src/tests/eldbus/eldbus_test_eldbus_model_signal.c
index 1a7e907905..954b424cbf 100644
--- a/src/tests/eldbus/eldbus_test_eldbus_model_signal.c
+++ b/src/tests/eldbus/eldbus_test_eldbus_model_signal.c
@@ -27,12 +27,18 @@ _setup(void)
27 27
28 fake_server = fake_server_start(&fake_server_data); 28 fake_server = fake_server_start(&fake_server_data);
29 29
30 Eldbus_Model_Connection* connection
31 = eo_add(ELDBUS_MODEL_CONNECTION_CLASS, NULL,
32 eldbus_model_connection_type_set(ELDBUS_CONNECTION_TYPE_SESSION),
33 eldbus_model_connection_address_set(NULL),
34 eldbus_model_connection_private_set(EINA_FALSE));
35
36 efl_model_load_and_wait_for_load_status(connection, EFL_MODEL_LOAD_STATUS_LOADED);
37
30 fake_server_object = eo_add(ELDBUS_MODEL_OBJECT_CLASS, NULL, 38 fake_server_object = eo_add(ELDBUS_MODEL_OBJECT_CLASS, NULL,
31 eldbus_model_object_constructor(ELDBUS_CONNECTION_TYPE_SESSION, 39 eldbus_model_object_connection_model_set(connection),
32 NULL, 40 eldbus_model_object_bus_set(FAKE_SERVER_BUS),
33 EINA_FALSE, 41 eldbus_model_object_path_set(FAKE_SERVER_PATH));
34 FAKE_SERVER_BUS,
35 FAKE_SERVER_PATH));
36 ck_assert_ptr_ne(NULL, fake_server_object); 42 ck_assert_ptr_ne(NULL, fake_server_object);
37 43
38 efl_model_load_and_wait_for_load_status(fake_server_object, EFL_MODEL_LOAD_STATUS_LOADED); 44 efl_model_load_and_wait_for_load_status(fake_server_object, EFL_MODEL_LOAD_STATUS_LOADED);
diff --git a/src/tests/eldbus/eldbus_test_fake_server_eldbus_model_proxy.c b/src/tests/eldbus/eldbus_test_fake_server_eldbus_model_proxy.c
index d4161b6b99..ce122b09d8 100644
--- a/src/tests/eldbus/eldbus_test_fake_server_eldbus_model_proxy.c
+++ b/src/tests/eldbus/eldbus_test_fake_server_eldbus_model_proxy.c
@@ -33,12 +33,18 @@ _setup(void)
33 }; 33 };
34 fake_server = fake_server_start(&fake_server_data); 34 fake_server = fake_server_start(&fake_server_data);
35 35
36 Eldbus_Model_Connection* connection
37 = eo_add(ELDBUS_MODEL_CONNECTION_CLASS, NULL,
38 eldbus_model_connection_type_set(ELDBUS_CONNECTION_TYPE_SESSION),
39 eldbus_model_connection_address_set(NULL),
40 eldbus_model_connection_private_set(EINA_FALSE));
41
42 efl_model_load_and_wait_for_load_status(connection, EFL_MODEL_LOAD_STATUS_LOADED);
43
36 fake_server_object = eo_add(ELDBUS_MODEL_OBJECT_CLASS, NULL, 44 fake_server_object = eo_add(ELDBUS_MODEL_OBJECT_CLASS, NULL,
37 eldbus_model_object_constructor(ELDBUS_CONNECTION_TYPE_SESSION, 45 eldbus_model_object_connection_model_set(connection),
38 NULL, 46 eldbus_model_object_bus_set(FAKE_SERVER_BUS),
39 EINA_FALSE, 47 eldbus_model_object_path_set(FAKE_SERVER_PATH));
40 FAKE_SERVER_BUS,
41 FAKE_SERVER_PATH));
42 ck_assert_ptr_ne(NULL, fake_server_object); 48 ck_assert_ptr_ne(NULL, fake_server_object);
43 49
44 efl_model_load_and_wait_for_load_status(fake_server_object, EFL_MODEL_LOAD_STATUS_LOADED); 50 efl_model_load_and_wait_for_load_status(fake_server_object, EFL_MODEL_LOAD_STATUS_LOADED);