hermet pushed a commit to branch master.

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

commit a62d254306b6045039d9b8d18ea19dcfe7855c05
Author: Mike Blumenkrantz <[email protected]>
Date:   Fri Jun 29 10:21:01 2018 +0900

    tests/eo: add explicit ref check when setting an invalid parent
    
    Summary: ref f4a55e9266520773de96bfc55b603443cd61696d
    
    Reviewers: bu5hm4n, devilhorns, Hermet
    
    Reviewed By: Hermet
    
    Subscribers: cedric, #committers
    
    Tags: #efl
    
    Differential Revision: https://phab.enlightenment.org/D6473
---
 src/tests/eo/suite/eo_test_general.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/src/tests/eo/suite/eo_test_general.c 
b/src/tests/eo/suite/eo_test_general.c
index 0418b6662f..acc35501d4 100644
--- a/src/tests/eo/suite/eo_test_general.c
+++ b/src/tests/eo/suite/eo_test_general.c
@@ -667,7 +667,11 @@ EFL_START_TEST(efl_refs)
    fail_if(!efl_invalidated_get(obj2));
    fail_if(!efl_invalidated_get(obj3));
 
-   efl_parent_set(obj2, obj3);
+   {
+      int ref_pre = efl_ref_count(obj2);
+      efl_parent_set(obj2, obj3);
+      ck_assert_int_eq(ref_pre, efl_ref_count(obj2));
+   }
 
    efl_unref(obj);
    efl_unref(obj2);

-- 


Reply via email to