summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2017-11-21 21:35:39 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2017-12-15 14:16:53 +0900
commitdb7fefc006520c4f5e17b928841e01068e5432c2 (patch)
treec03be98323be1127781b98bdbb8529a71d79a18e
parentc4e96e4e8388c6e20e06f2723309f573b914c0b1 (diff)
efl model tests - fix mainloop iterate to not assume a single iter
it may have to loop multiple times as there isnt a guarantee on WHEN the result comes back.... :)
-rw-r--r--src/tests/efl/efl_test_model_composite.c4
-rw-r--r--src/tests/efl/efl_test_model_container.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/tests/efl/efl_test_model_composite.c b/src/tests/efl/efl_test_model_composite.c
index a38e776746..175adee339 100644
--- a/src/tests/efl/efl_test_model_composite.c
+++ b/src/tests/efl/efl_test_model_composite.c
@@ -204,7 +204,7 @@ START_TEST(efl_test_model_composite_boolean)
204 future = efl_model_children_slice_get(model, 0, 0); 204 future = efl_model_children_slice_get(model, 0, 0);
205 efl_future_then(future, _children_slice_get_then, _future_error_then, NULL, tdata); 205 efl_future_then(future, _children_slice_get_then, _future_error_then, NULL, tdata);
206 206
207 ecore_main_loop_iterate(); 207 while (!tdata->success_flag) ecore_main_loop_iterate();
208 208
209 ck_assert(tdata->success_flag); 209 ck_assert(tdata->success_flag);
210 210
@@ -246,7 +246,7 @@ START_TEST(efl_test_model_composite_selection)
246 future = efl_model_children_slice_get(model, 0, 0); 246 future = efl_model_children_slice_get(model, 0, 0);
247 efl_future_then(future, _selection_children_slice_get_then, _future_error_then, NULL, tdata); 247 efl_future_then(future, _selection_children_slice_get_then, _future_error_then, NULL, tdata);
248 248
249 ecore_main_loop_iterate(); 249 while (!tdata->success_flag) ecore_main_loop_iterate();
250 250
251 ck_assert(tdata->success_flag); 251 ck_assert(tdata->success_flag);
252 252
diff --git a/src/tests/efl/efl_test_model_container.c b/src/tests/efl/efl_test_model_container.c
index 5710ef2337..bfd1984d4d 100644
--- a/src/tests/efl/efl_test_model_container.c
+++ b/src/tests/efl/efl_test_model_container.c
@@ -154,7 +154,7 @@ START_TEST(efl_test_model_container_values)
154 154
155 efl_future_then(future, _children_slice_future_then, _future_error_then, NULL, &test_data); 155 efl_future_then(future, _children_slice_future_then, _future_error_then, NULL, &test_data);
156 156
157 ecore_main_loop_iterate(); 157 while ((!test_data.pass_flag) && (!test_data.fail_flag)) ecore_main_loop_iterate();
158 158
159 ck_assert(!!test_data.pass_flag); 159 ck_assert(!!test_data.pass_flag);
160 ck_assert(!test_data.fail_flag); 160 ck_assert(!test_data.fail_flag);