From: Edward Hervey Date: Fri, 6 Jul 2012 09:40:47 +0000 (+0200) Subject: check: Use consistencycheck on basesrc X-Git-Tag: RELEASE-0.11.93~158 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0efc42aac7aed22c19f29603cf136bdbd45fc3b8;p=platform%2Fupstream%2Fgstreamer.git check: Use consistencycheck on basesrc --- diff --git a/tests/check/libs/basesrc.c b/tests/check/libs/basesrc.c index 7e09488..21e2481 100644 --- a/tests/check/libs/basesrc.c +++ b/tests/check/libs/basesrc.c @@ -25,6 +25,7 @@ #endif #include #include +#include #include static GstPadProbeReturn @@ -54,6 +55,7 @@ GST_START_TEST (basesrc_eos_events_push_live_op) GstBus *bus; GstPad *srcpad; guint probe, num_eos = 0; + GstStreamConsistency *consistency; pipe = gst_pipeline_new ("pipeline"); sink = gst_element_factory_make ("fakesink", "sink"); @@ -78,6 +80,8 @@ GST_START_TEST (basesrc_eos_events_push_live_op) srcpad = gst_element_get_static_pad (src, "src"); fail_unless (srcpad != NULL); + consistency = gst_consistency_checker_new (srcpad); + probe = gst_pad_add_probe (srcpad, GST_PAD_PROBE_TYPE_EVENT_BOTH, (GstPadProbeCallback) eos_event_counter, &num_eos, NULL); @@ -108,6 +112,8 @@ GST_START_TEST (basesrc_eos_events_push_live_op) /* make sure source hasn't sent a second one when going PAUSED => READY */ fail_unless (num_eos == 1); + gst_consistency_checker_free (consistency); + gst_pad_remove_probe (srcpad, probe); gst_object_unref (srcpad); gst_message_unref (msg); @@ -131,6 +137,7 @@ GST_START_TEST (basesrc_eos_events_push) GstBus *bus; GstPad *srcpad; guint probe, num_eos = 0; + GstStreamConsistency *consistency; pipe = gst_pipeline_new ("pipeline"); sink = gst_element_factory_make ("fakesink", "sink"); @@ -156,6 +163,8 @@ GST_START_TEST (basesrc_eos_events_push) srcpad = gst_element_get_static_pad (src, "src"); fail_unless (srcpad != NULL); + consistency = gst_consistency_checker_new (srcpad); + probe = gst_pad_add_probe (srcpad, GST_PAD_PROBE_TYPE_EVENT_BOTH, (GstPadProbeCallback) eos_event_counter, &num_eos, NULL); @@ -179,6 +188,8 @@ GST_START_TEST (basesrc_eos_events_push) /* make sure source hasn't sent a second one when going PAUSED => READY */ fail_unless (num_eos == 1); + gst_consistency_checker_free (consistency); + gst_pad_remove_probe (srcpad, probe); gst_object_unref (srcpad); gst_message_unref (msg);