cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=c255849fdc8227f8204e405a9a1421ed4371d4c3

commit c255849fdc8227f8204e405a9a1421ed4371d4c3
Author: Cedric BAIL <[email protected]>
Date:   Mon Dec 23 11:42:12 2013 +0900

    eldbus: fix tests to properly take into account the presence of ecore 
system module.
    
    Ecore system module may use dbus, so when you init ecore, it may init 
eldbus a few
    more time (depending on the module that are present on your system). This 
result in
    eldbus_init returning a valid init, but different from 1. This patch update 
the test
    to take that into account.
---
 src/tests/eldbus/eldbus_test_eldbus_init.c | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/src/tests/eldbus/eldbus_test_eldbus_init.c 
b/src/tests/eldbus/eldbus_test_eldbus_init.c
index efe92cd..f530d4c 100644
--- a/src/tests/eldbus/eldbus_test_eldbus_init.c
+++ b/src/tests/eldbus/eldbus_test_eldbus_init.c
@@ -23,10 +23,9 @@ START_TEST(eldbus_test_eldbus)
    int ret;
 
    ret = eldbus_init();
-   fail_if(ret != 1);
+   fail_if(ret < 1);
 
    ret = eldbus_shutdown();
-   fail_if(ret != 0);
 }
 END_TEST
 
@@ -37,7 +36,7 @@ START_TEST(eldbus_test_eldbus_main_loop)
 
    ecore_init();
    ret = eldbus_init();
-   fail_if(ret != 1);
+   fail_if(ret < 1);
 
    timer = ecore_timer_add(0.1, _quit_cb, NULL);
    fail_if(timer == NULL);
@@ -45,7 +44,6 @@ START_TEST(eldbus_test_eldbus_main_loop)
    ecore_main_loop_begin();
 
    ret = eldbus_shutdown();
-   fail_if(ret != 0);
 
    ecore_shutdown();
 
@@ -67,7 +65,7 @@ START_TEST(eldbus_test_eldbus_conn)
    ecore_init();
 
    ret = eldbus_init();
-   fail_if(ret != 1);
+   fail_if(ret < 1);
 
    /*
     * let's use connection type == system, so it works without a session,
@@ -80,7 +78,6 @@ START_TEST(eldbus_test_eldbus_conn)
    eldbus_connection_unref(conn);
 
    ret = eldbus_shutdown();
-   fail_if(ret != 0);
 
    ecore_shutdown();
 
@@ -96,7 +93,7 @@ START_TEST(eldbus_test_eldbus_conn_object)
    ecore_init();
 
    ret = eldbus_init();
-   fail_if(ret != 1);
+   fail_if(ret < 1);
 
    /*
     * let's use connection type == system, so it works without a D-Bus session.
@@ -114,7 +111,6 @@ START_TEST(eldbus_test_eldbus_conn_object)
    eldbus_connection_unref(conn);
 
    ret = eldbus_shutdown();
-   fail_if(ret != 0);
 
    ecore_shutdown();
 

-- 


Reply via email to