Added step to process deferred job for windows 84/48884/1
authorMinJeong Kim <minjjj.kim@samsung.com>
Thu, 1 Oct 2015 06:33:59 +0000 (15:33 +0900)
committerMinJeong Kim <minjjj.kim@samsung.com>
Thu, 1 Oct 2015 06:42:45 +0000 (15:42 +0900)
Change-Id: I6ae86cdcb7b48eb51db814ad8c7e4cb469445a74
Signed-off-by: MinJeong Kim <minjjj.kim@samsung.com>
src/0100_base_operation.c
src/0200_transient_for.c
src/0300_notification.c
src/e_test_runner.c
src/e_test_runner.h

index 41a62c4..cf2a98e 100644 (file)
@@ -32,6 +32,8 @@ _tc_pre_run(E_TC *tc, Eina_Bool alpha)
    res = e_test_runner_ev_wait(tc->runner, E_TC_EVENT_TYPE_VIS_ON);
    EINA_SAFETY_ON_FALSE_GOTO(res, cleanup);
 
+   e_test_runner_work();
+
    return EINA_TRUE;
 
 cleanup:
index 0a5b205..345d404 100644 (file)
@@ -57,6 +57,8 @@ _tc_pre_run(E_TC *tc)
                                     EINA_TRUE);
    EINA_SAFETY_ON_FALSE_GOTO(res, cleanup);
 
+   e_test_runner_work();
+
    return EINA_TRUE;
 
 cleanup:
index fee6316..e1b3a57 100644 (file)
@@ -79,6 +79,8 @@ _tc_pre_run(E_TC *tc)
    res = e_test_runner_ev_wait(tc->runner, E_TC_EVENT_TYPE_VIS_CHANGED);
    EINA_SAFETY_ON_FALSE_GOTO(res, cleanup);
 
+   e_test_runner_work();
+
    return EINA_TRUE;
 
 cleanup:
index 7c92f18..71cb10e 100644 (file)
@@ -1,5 +1,7 @@
 #include "e_test_runner.h"
 
+#define E_TEST_RUNNER_WORK_TIME 0.3
+
 int _log_dom = -1;
 
 #if HAVE_WAYLAND
@@ -247,6 +249,13 @@ finish:
 }
 
 static Eina_Bool
+_cb_work_time_out(void *data EINA_UNUSED)
+{
+   elm_exit();
+   return ECORE_CALLBACK_CANCEL;
+}
+
+static Eina_Bool
 _ev_wait_timeout(void *data)
 {
    E_Test_Runner *runner = data;
@@ -410,6 +419,14 @@ finish:
    return res;
 }
 
+void
+e_test_runner_work(void)
+{
+   /* give a turn to deal with deferred job for E_TEST_RUNNER_WORK_TIME */
+   ecore_timer_add(E_TEST_RUNNER_WORK_TIME, _cb_work_time_out, NULL);
+   elm_run();
+}
+
 E_TC_Win *
 e_tc_win_add(E_TC_Win *parent,
              Elm_Win_Type type,
index e897c6a..ef0d684 100644 (file)
@@ -137,6 +137,7 @@ void       e_tc_win_geom_update(E_TC_Win *tw);
 void       e_tc_win_show(E_TC_Win *tw);
 void       e_tc_win_hide(E_TC_Win *tw);
 Eina_Bool  e_tc_win_transient_for_set(E_TC_Win *tw_parent, E_TC_Win *tw_child, Eina_Bool set);
+void       e_test_runner_work(void);
 
 /* test cases */
 Eina_Bool  tc_0000_base_pass(E_TC *tc);