[0.11] gst-plugins-good: tests: fix jpeg test

Wim Taymans wtay at kemper.freedesktop.org
Tue Feb 7 01:39:50 PST 2012


Module: gst-plugins-good
Branch: 0.11
Commit: 3644e23184cf40bcaab1bde208fe3157a06d5e27
URL:    http://cgit.freedesktop.org/gstreamer/gst-plugins-good/commit/?id=3644e23184cf40bcaab1bde208fe3157a06d5e27

Author: Wim Taymans <wim.taymans at collabora.co.uk>
Date:   Tue Feb  7 10:16:32 2012 +0100

tests: fix jpeg test

---

 tests/check/elements/jpegenc.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/tests/check/elements/jpegenc.c b/tests/check/elements/jpegenc.c
index b242f8e..1044b4e 100644
--- a/tests/check/elements/jpegenc.c
+++ b/tests/check/elements/jpegenc.c
@@ -195,7 +195,8 @@ GST_START_TEST (test_jpegenc_different_caps)
   caps = gst_caps_new_simple ("video/x-raw", "width", G_TYPE_INT,
       800, "height", G_TYPE_INT, 600, "framerate",
       GST_TYPE_FRACTION, 1, 1, "format", G_TYPE_STRING, "I420", NULL);
-  buffer = create_video_buffer (caps);
+  fail_unless (gst_pad_set_caps (mysrcpad, caps));
+  fail_unless ((buffer = create_video_buffer (caps)) != NULL);
   gst_caps_unref (caps);
   fail_unless (gst_pad_push (mysrcpad, buffer) == GST_FLOW_OK);
 
@@ -208,6 +209,7 @@ GST_START_TEST (test_jpegenc_different_caps)
       640, "height", G_TYPE_INT, 480, "framerate",
       GST_TYPE_FRACTION, 1, 1, "format", G_TYPE_STRING, "I420", NULL);
   fail_unless (gst_caps_can_intersect (allowed_caps, caps));
+  fail_unless (gst_pad_set_caps (mysrcpad, caps));
 
   /* push second buffer with 640x480 resolution */
   buffer = create_video_buffer (caps);



More information about the gstreamer-commits mailing list