tests: update for gstcheck API change

This commit is contained in:
René Stadler 2011-11-24 21:41:03 +01:00
parent 32365953c3
commit a806ae2edd
28 changed files with 64 additions and 60 deletions

View file

@ -43,8 +43,8 @@ setup_alphacolor (void)
GstElement *alphacolor;
alphacolor = gst_check_setup_element ("alphacolor");
mysrcpad = gst_check_setup_src_pad (alphacolor, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (alphacolor, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (alphacolor, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (alphacolor, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -65,8 +65,8 @@ setup_amplify (void)
GST_DEBUG ("setup_amplify");
amplify = gst_check_setup_element ("audioamplify");
mysrcpad = gst_check_setup_src_pad (amplify, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (amplify, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (amplify, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (amplify, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -70,8 +70,8 @@ setup_audiochebband (void)
GST_DEBUG ("setup_audiochebband");
audiochebband = gst_check_setup_element ("audiochebband");
mysrcpad = gst_check_setup_src_pad (audiochebband, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (audiochebband, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (audiochebband, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (audiochebband, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -70,8 +70,8 @@ setup_audiocheblimit (void)
GST_DEBUG ("setup_audiocheblimit");
audiocheblimit = gst_check_setup_element ("audiocheblimit");
mysrcpad = gst_check_setup_src_pad (audiocheblimit, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (audiocheblimit, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (audiocheblimit, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (audiocheblimit, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -65,8 +65,8 @@ setup_dynamic (void)
GST_DEBUG ("setup_dynamic");
dynamic = gst_check_setup_element ("audiodynamic");
mysrcpad = gst_check_setup_src_pad (dynamic, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (dynamic, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (dynamic, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (dynamic, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -60,8 +60,8 @@ setup_echo (void)
GST_DEBUG ("setup_echo");
echo = gst_check_setup_element ("audioecho");
mysrcpad = gst_check_setup_src_pad (echo, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (echo, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (echo, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (echo, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -64,8 +64,8 @@ setup_invert (void)
GST_DEBUG ("setup_invert");
invert = gst_check_setup_element ("audioinvert");
mysrcpad = gst_check_setup_src_pad (invert, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (invert, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (invert, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (invert, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -85,8 +85,8 @@ setup_panorama_m (void)
GST_DEBUG ("setup_panorama");
panorama = gst_check_setup_element ("audiopanorama");
mysrcpad = gst_check_setup_src_pad (panorama, &msrctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (panorama, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (panorama, &msrctemplate);
mysinkpad = gst_check_setup_sink_pad (panorama, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);
@ -100,8 +100,8 @@ setup_panorama_s (void)
GST_DEBUG ("setup_panorama");
panorama = gst_check_setup_element ("audiopanorama");
mysrcpad = gst_check_setup_src_pad (panorama, &ssrctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (panorama, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (panorama, &ssrctemplate);
mysinkpad = gst_check_setup_sink_pad (panorama, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -69,8 +69,8 @@ setup_audiowsincband (void)
GST_DEBUG ("setup_audiowsincband");
audiowsincband = gst_check_setup_element ("audiowsincband");
mysrcpad = gst_check_setup_src_pad (audiowsincband, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (audiowsincband, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (audiowsincband, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (audiowsincband, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -69,8 +69,8 @@ setup_audiowsinclimit (void)
GST_DEBUG ("setup_audiowsinclimit");
audiowsinclimit = gst_check_setup_element ("audiowsinclimit");
mysrcpad = gst_check_setup_src_pad (audiowsinclimit, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (audiowsinclimit, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (audiowsinclimit, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (audiowsinclimit, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -123,7 +123,7 @@ setup_avimux (GstStaticPadTemplate * srctemplate, const gchar * sinkname)
GST_DEBUG ("setup_avimux");
avimux = gst_check_setup_element ("avimux");
mysrcpad = setup_src_pad (avimux, srctemplate, NULL, sinkname);
mysinkpad = gst_check_setup_sink_pad (avimux, &sinktemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (avimux, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -70,18 +70,20 @@ static GstElement *
setup_avisubtitle (void)
{
GstElement *avisubtitle;
GstCaps *caps;
GstCaps *sinkcaps, *srccaps;
GST_DEBUG ("setup_avisubtitle");
avisubtitle = gst_check_setup_element ("avisubtitle");
caps = gst_caps_new_simple ("application/x-subtitle", NULL);
mysinkpad = gst_check_setup_sink_pad (avisubtitle, &sink_template, caps);
gst_caps_unref (caps);
caps = gst_caps_new_simple ("application/x-subtitle-avi", NULL);
mysrcpad = gst_check_setup_src_pad (avisubtitle, &src_template, caps);
gst_caps_unref (caps);
sinkcaps = gst_caps_new_empty_simple ("application/x-subtitle");
mysinkpad = gst_check_setup_sink_pad (avisubtitle, &sink_template);
srccaps = gst_caps_new_empty_simple ("application/x-subtitle-avi");
mysrcpad = gst_check_setup_src_pad (avisubtitle, &src_template);
gst_pad_set_active (mysinkpad, TRUE);
gst_pad_set_active (mysrcpad, TRUE);
fail_unless (gst_pad_set_caps (mysinkpad, sinkcaps));
fail_unless (gst_pad_set_caps (mysrcpad, srccaps));
gst_caps_unref (sinkcaps);
gst_caps_unref (srccaps);
return avisubtitle;
}

View file

@ -48,8 +48,8 @@ setup_capssetter (void)
GST_DEBUG ("setup_capssetter");
capssetter = gst_check_setup_element ("capssetter");
mysrcpad = gst_check_setup_src_pad (capssetter, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (capssetter, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (capssetter, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (capssetter, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -138,8 +138,8 @@ setup_cmmldec (void)
{
GST_DEBUG ("setup_cmmldec");
cmmldec = gst_check_setup_element ("cmmldec");
srcpad = gst_check_setup_src_pad (cmmldec, &srctemplate, NULL);
sinkpad = gst_check_setup_sink_pad (cmmldec, &sinktemplate, NULL);
srcpad = gst_check_setup_src_pad (cmmldec, &srctemplate);
sinkpad = gst_check_setup_sink_pad (cmmldec, &sinktemplate);
gst_pad_set_active (srcpad, TRUE);
gst_pad_set_active (sinkpad, TRUE);

View file

@ -157,8 +157,8 @@ setup_cmmlenc (void)
GST_DEBUG ("setup_cmmlenc");
cmmlenc = gst_check_setup_element ("cmmlenc");
srcpad = gst_check_setup_src_pad (cmmlenc, &srctemplate, NULL);
sinkpad = gst_check_setup_sink_pad (cmmlenc, &sinktemplate, NULL);
srcpad = gst_check_setup_src_pad (cmmlenc, &srctemplate);
sinkpad = gst_check_setup_sink_pad (cmmlenc, &sinktemplate);
gst_pad_set_active (srcpad, TRUE);
gst_pad_set_active (sinkpad, TRUE);

View file

@ -62,8 +62,8 @@ setup_equalizer (void)
GST_DEBUG ("setup_equalizer");
equalizer = gst_check_setup_element ("equalizer-nbands");
mysrcpad = gst_check_setup_src_pad (equalizer, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (equalizer, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (equalizer, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (equalizer, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -103,7 +103,7 @@ static GstElement *
create_icydemux (void)
{
icydemux = gst_check_setup_element ("icydemux");
srcpad = gst_check_setup_src_pad (icydemux, &srctemplate, NULL);
srcpad = gst_check_setup_src_pad (icydemux, &srctemplate);
g_signal_connect (icydemux, "pad-added", G_CALLBACK (icydemux_found_pad),
NULL);

View file

@ -67,8 +67,8 @@ setup_jpegenc (GstStaticPadTemplate * sinktemplate)
GST_DEBUG ("setup_jpegenc");
jpegenc = gst_check_setup_element ("jpegenc");
mysinkpad = gst_check_setup_sink_pad (jpegenc, sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (jpegenc, &any_srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (jpegenc, sinktemplate);
mysrcpad = gst_check_setup_src_pad (jpegenc, &any_srctemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -63,8 +63,8 @@ setup_level (void)
GST_DEBUG ("setup_level");
level = gst_check_setup_element ("level");
mysrcpad = gst_check_setup_src_pad (level, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (level, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (level, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (level, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -150,10 +150,12 @@ setup_element (const gchar * factory, GstStaticPadTemplate * sink_template,
GstBus *bus;
element = gst_check_setup_element (factory);
srcpad = gst_check_setup_src_pad (element, src_template, src_caps);
sinkpad = gst_check_setup_sink_pad (element, sink_template, sink_caps);
srcpad = gst_check_setup_src_pad (element, src_template);
sinkpad = gst_check_setup_sink_pad (element, sink_template);
gst_pad_set_active (srcpad, TRUE);
gst_pad_set_active (sinkpad, TRUE);
fail_unless (gst_pad_set_caps (srcpad, src_caps));
fail_unless (gst_pad_set_caps (sinkpad, sink_caps));
bus = gst_bus_new ();
gst_element_set_bus (element, bus);

View file

@ -161,7 +161,7 @@ setup_qtmux (GstStaticPadTemplate * srctemplate, const gchar * sinkname)
GST_DEBUG ("setup_qtmux");
qtmux = gst_check_setup_element ("qtmux");
mysrcpad = setup_src_pad (qtmux, srctemplate, NULL, sinkname);
mysinkpad = gst_check_setup_sink_pad (qtmux, &sinktemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (qtmux, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -155,8 +155,8 @@ setup_rganalysis (void)
GST_DEBUG ("setup_rganalysis");
analysis = gst_check_setup_element ("rganalysis");
mysrcpad = gst_check_setup_src_pad (analysis, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (analysis, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (analysis, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (analysis, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -54,8 +54,8 @@ setup_rglimiter (void)
GST_DEBUG ("setup_rglimiter");
element = gst_check_setup_element ("rglimiter");
mysrcpad = gst_check_setup_src_pad (element, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (element, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (element, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (element, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -66,8 +66,8 @@ setup_rgvolume (void)
GST_DEBUG ("setup_rgvolume");
element = gst_check_setup_element ("rgvolume");
mysrcpad = gst_check_setup_src_pad (element, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (element, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (element, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (element, &sinktemplate);
/* Capture events, to test tag filtering behavior: */
gst_pad_set_event_function (mysinkpad, event_func);

View file

@ -94,8 +94,8 @@ setup_jitterbuffer (gint num_buffers)
GST_INFO_OBJECT (jitterbuffer, "set latency to %u ms", latency);
*/
mysrcpad = gst_check_setup_src_pad (jitterbuffer, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (jitterbuffer, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (jitterbuffer, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (jitterbuffer, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -87,8 +87,8 @@ setup_spectrum (void)
GST_DEBUG ("setup_spectrum");
spectrum = gst_check_setup_element ("spectrum");
mysrcpad = gst_check_setup_src_pad (spectrum, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (spectrum, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (spectrum, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (spectrum, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);

View file

@ -61,9 +61,9 @@ setup_filter (const gchar * name, const gchar * prop, va_list var_args)
GST_DEBUG ("setup_element");
element = gst_check_setup_element (name);
g_object_set_valist (G_OBJECT (element), prop, var_args);
mysrcpad = gst_check_setup_src_pad (element, &srctemplate, NULL);
mysrcpad = gst_check_setup_src_pad (element, &srctemplate);
gst_pad_set_active (mysrcpad, TRUE);
mysinkpad = gst_check_setup_sink_pad (element, &sinktemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (element, &sinktemplate);
gst_pad_set_active (mysinkpad, TRUE);
return element;

View file

@ -57,8 +57,8 @@ setup_y4menc (void)
GST_DEBUG ("setup_y4menc");
y4menc = gst_check_setup_element ("y4menc");
mysrcpad = gst_check_setup_src_pad (y4menc, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (y4menc, &sinktemplate, NULL);
mysrcpad = gst_check_setup_src_pad (y4menc, &srctemplate);
mysinkpad = gst_check_setup_sink_pad (y4menc, &sinktemplate);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);