From: Thibault Saunier Date: Thu, 1 Dec 2016 18:46:51 +0000 (-0300) Subject: test:nle: Soften check on refcount X-Git-Tag: 1.19.3~493^2~881 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b6b640d0462a7585eb084627d1828e702c0ee6c6;p=platform%2Fupstream%2Fgstreamer.git test:nle: Soften check on refcount The composition might already have taken a new ref processing the source. --- diff --git a/tests/check/nle/nleoperation.c b/tests/check/nle/nleoperation.c index b111c4a..a1d106c 100644 --- a/tests/check/nle/nleoperation.c +++ b/tests/check/nle/nleoperation.c @@ -545,12 +545,16 @@ GST_START_TEST (test_complex_operations) /* Add source1 */ nle_composition_add (GST_BIN (comp), source1); check_start_stop_duration (comp, 0, 0, 0); - ASSERT_OBJECT_REFCOUNT (source1, "source1", 1); + /* If the composition already processed the source, the refcount + * might be 2 */ + ASSERT_OBJECT_REFCOUNT_BETWEEN (source1, "source1", 1, 2); /* Add source2 */ nle_composition_add (GST_BIN (comp), source2); check_start_stop_duration (comp, 0, 0, 0); - ASSERT_OBJECT_REFCOUNT (source2, "source2", 1); + /* If the composition already processed the source, the refcount + * might be 2 */ + ASSERT_OBJECT_REFCOUNT_BETWEEN (source2, "source2", 1, 2); /* Add operaton */ nle_composition_add (GST_BIN (comp), oper);