faad/faac: Fix event handling in unit test

This commit is contained in:
Sebastian Dröge 2013-05-15 09:41:54 +02:00
parent 1c16489af7
commit 75bb160459
2 changed files with 3 additions and 2 deletions

View file

@ -119,7 +119,7 @@ do_test (gboolean adts)
/* makes valgrind's memcheck happier */
gst_buffer_memset (inbuffer, 0, 0, 1024 * nbuffers * 2 * 2);
caps = gst_caps_from_string (AUDIO_CAPS_STRING);
gst_pad_set_caps (mysrcpad, caps);
gst_check_setup_events (mysrcpad, faac, caps, GST_FORMAT_TIME);
gst_caps_unref (caps);
GST_BUFFER_TIMESTAMP (inbuffer) = 0;
ASSERT_BUFFER_REFCOUNT (inbuffer, "inbuffer", 1);

View file

@ -97,7 +97,8 @@ do_test (GstBuffer * inbuffer, GstCaps * caps)
GST_BUFFER_TIMESTAMP (inbuffer) = 0;
ASSERT_BUFFER_REFCOUNT (inbuffer, "inbuffer", 1);
gst_pad_set_caps (mysrcpad, caps);
gst_check_setup_events (mysrcpad, faad, caps, GST_FORMAT_TIME);
/* need to push twice to get faad output */
gst_buffer_ref (inbuffer);
fail_unless (gst_pad_push (mysrcpad, inbuffer) == GST_FLOW_OK);