tests/check/elements/playbin.c: Add small test for stream-info-value-array code paths.
authorTim-Philipp Müller <tim@centricular.net>
Fri, 6 Apr 2007 09:56:18 +0000 (09:56 +0000)
committerTim-Philipp Müller <tim@centricular.net>
Fri, 6 Apr 2007 09:56:18 +0000 (09:56 +0000)
Original commit message from CVS:
* tests/check/elements/playbin.c:
(test_sink_usage_video_only_stream), (playbin_suite):
Add small test for stream-info-value-array code paths.

ChangeLog
tests/check/elements/playbin.c

index 6f85981..ae1be90 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2007-04-06  Tim-Philipp Müller  <tim at centricular dot net>
+
+       * tests/check/elements/playbin.c:
+       (test_sink_usage_video_only_stream), (playbin_suite):
+         Add small test for stream-info-value-array code paths.
+
 2007-04-05  Wim Taymans  <wim@fluendo.com>
 
        * gst-libs/gst/audio/gstbaseaudiosink.c:
index 1d2f222..ae18efd 100644 (file)
@@ -76,6 +76,15 @@ DEFINE_TEST (test_sink_usage_video_only_stream)
   fail_unless_equals_int (cur_state, GST_STATE_NULL);
   fail_unless_equals_int (pending_state, GST_STATE_VOID_PENDING);
 
+  {
+    GValueArray *stream_info = NULL;
+
+    g_object_get (playbin, "stream-info-value-array", &stream_info, NULL);
+    fail_unless (stream_info != NULL);
+    fail_unless_equals_int (stream_info->n_values, 1);
+    g_value_array_free (stream_info);
+  }
+
   gst_element_set_state (playbin, GST_STATE_NULL);
   gst_object_unref (playbin);
 }