Commit 5f8d6ab7 authored by Stefan Kost's avatar Stefan Kost
Browse files

tests/check/elements/: consistent pad (de)activation

Original commit message from CVS:
* tests/check/elements/audioresample.c: (cleanup_audioresample):
* tests/check/elements/audiotestsrc.c: (cleanup_audiotestsrc):
* tests/check/elements/gdpdepay.c: (setup_gdpdepay),
(cleanup_gdpdepay):
* tests/check/elements/gdppay.c: (setup_gdppay), (cleanup_gdppay):
* tests/check/elements/subparse.c: (teardown_subparse):
* tests/check/elements/textoverlay.c: (cleanup_textoverlay):
* tests/check/elements/videorate.c: (cleanup_videorate):
* tests/check/elements/videotestsrc.c: (cleanup_videotestsrc):
* tests/check/elements/volume.c: (cleanup_volume):
* tests/check/elements/vorbisdec.c: (setup_vorbisdec),
(cleanup_vorbisdec):
* tests/check/elements/vorbistag.c: (setup_vorbistag),
(cleanup_vorbistag):
consistent pad (de)activation
parent a9c59c04
2006-12-21 Stefan Kost <ensonic@users.sf.net>
* tests/check/elements/audioresample.c: (cleanup_audioresample):
* tests/check/elements/audiotestsrc.c: (cleanup_audiotestsrc):
* tests/check/elements/gdpdepay.c: (setup_gdpdepay),
(cleanup_gdpdepay):
* tests/check/elements/gdppay.c: (setup_gdppay), (cleanup_gdppay):
* tests/check/elements/subparse.c: (teardown_subparse):
* tests/check/elements/textoverlay.c: (cleanup_textoverlay):
* tests/check/elements/videorate.c: (cleanup_videorate):
* tests/check/elements/videotestsrc.c: (cleanup_videotestsrc):
* tests/check/elements/volume.c: (cleanup_volume):
* tests/check/elements/vorbisdec.c: (setup_vorbisdec),
(cleanup_vorbisdec):
* tests/check/elements/vorbistag.c: (setup_vorbistag),
(cleanup_vorbistag):
consistent pad (de)activation
2006-12-20 Tim-Philipp Müller <tim at centricular dot net> 2006-12-20 Tim-Philipp Müller <tim at centricular dot net>
   
* gst/typefind/gsttypefindfunctions.c: (plugin_init): * gst/typefind/gsttypefindfunctions.c: (plugin_init):
...@@ -108,6 +108,8 @@ cleanup_audioresample (GstElement * audioresample) ...@@ -108,6 +108,8 @@ cleanup_audioresample (GstElement * audioresample)
fail_unless (gst_element_set_state (audioresample, fail_unless (gst_element_set_state (audioresample,
GST_STATE_NULL) == GST_STATE_CHANGE_SUCCESS, "could not set to NULL"); GST_STATE_NULL) == GST_STATE_CHANGE_SUCCESS, "could not set to NULL");
gst_pad_set_active (mysrcpad, FALSE);
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_src_pad (audioresample); gst_check_teardown_src_pad (audioresample);
gst_check_teardown_sink_pad (audioresample); gst_check_teardown_sink_pad (audioresample);
gst_check_teardown_element (audioresample); gst_check_teardown_element (audioresample);
......
...@@ -69,6 +69,7 @@ cleanup_audiotestsrc (GstElement * audiotestsrc) ...@@ -69,6 +69,7 @@ cleanup_audiotestsrc (GstElement * audiotestsrc)
g_list_free (buffers); g_list_free (buffers);
buffers = NULL; buffers = NULL;
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_sink_pad (audiotestsrc); gst_check_teardown_sink_pad (audiotestsrc);
gst_check_teardown_element (audiotestsrc); gst_check_teardown_element (audiotestsrc);
} }
......
...@@ -72,6 +72,8 @@ setup_gdpdepay () ...@@ -72,6 +72,8 @@ setup_gdpdepay ()
gdpdepay = gst_check_setup_element ("gdpdepay"); gdpdepay = gst_check_setup_element ("gdpdepay");
mysrcpad = gst_check_setup_src_pad (gdpdepay, &srctemplate, NULL); mysrcpad = gst_check_setup_src_pad (gdpdepay, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (gdpdepay, &sinktemplate, NULL); mysinkpad = gst_check_setup_sink_pad (gdpdepay, &sinktemplate, NULL);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);
return gdpdepay; return gdpdepay;
} }
...@@ -81,6 +83,8 @@ cleanup_gdpdepay (GstElement * gdpdepay) ...@@ -81,6 +83,8 @@ cleanup_gdpdepay (GstElement * gdpdepay)
{ {
GST_DEBUG ("cleanup_gdpdepay"); GST_DEBUG ("cleanup_gdpdepay");
gst_pad_set_active (mysrcpad, FALSE);
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_src_pad (gdpdepay); gst_check_teardown_src_pad (gdpdepay);
gst_check_teardown_sink_pad (gdpdepay); gst_check_teardown_sink_pad (gdpdepay);
gst_check_teardown_element (gdpdepay); gst_check_teardown_element (gdpdepay);
......
...@@ -71,6 +71,8 @@ setup_gdppay () ...@@ -71,6 +71,8 @@ setup_gdppay ()
gdppay = gst_check_setup_element ("gdppay"); gdppay = gst_check_setup_element ("gdppay");
mysrcpad = gst_check_setup_src_pad (gdppay, &srctemplate, NULL); mysrcpad = gst_check_setup_src_pad (gdppay, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (gdppay, &sinktemplate, NULL); mysinkpad = gst_check_setup_sink_pad (gdppay, &sinktemplate, NULL);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);
return gdppay; return gdppay;
} }
...@@ -80,6 +82,8 @@ cleanup_gdppay (GstElement * gdppay) ...@@ -80,6 +82,8 @@ cleanup_gdppay (GstElement * gdppay)
{ {
GST_DEBUG ("cleanup_gdppay"); GST_DEBUG ("cleanup_gdppay");
gst_pad_set_active (mysrcpad, FALSE);
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_src_pad (gdppay); gst_check_teardown_src_pad (gdppay);
gst_check_teardown_sink_pad (gdppay); gst_check_teardown_sink_pad (gdppay);
gst_check_teardown_element (gdppay); gst_check_teardown_element (gdppay);
......
...@@ -125,6 +125,8 @@ teardown_subparse (void) ...@@ -125,6 +125,8 @@ teardown_subparse (void)
g_list_free (buffers); g_list_free (buffers);
buffers = NULL; buffers = NULL;
gst_pad_set_active (mysrcpad, FALSE);
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_sink_pad (subparse); gst_check_teardown_sink_pad (subparse);
gst_check_teardown_src_pad (subparse); gst_check_teardown_src_pad (subparse);
gst_check_teardown_element (subparse); gst_check_teardown_element (subparse);
......
...@@ -255,6 +255,8 @@ cleanup_textoverlay (GstElement * textoverlay) ...@@ -255,6 +255,8 @@ cleanup_textoverlay (GstElement * textoverlay)
gst_element_set_state (textoverlay, GST_STATE_NULL); gst_element_set_state (textoverlay, GST_STATE_NULL);
gst_element_get_state (textoverlay, NULL, NULL, GST_CLOCK_TIME_NONE); gst_element_get_state (textoverlay, NULL, NULL, GST_CLOCK_TIME_NONE);
gst_pad_set_active (myvideosrcpad, FALSE);
gst_pad_set_active (mysinkpad, FALSE);
notgst_check_teardown_src_pad2 (textoverlay, "video_sink"); notgst_check_teardown_src_pad2 (textoverlay, "video_sink");
if (mytextsrcpad) { if (mytextsrcpad) {
notgst_check_teardown_src_pad2 (textoverlay, "text_sink"); notgst_check_teardown_src_pad2 (textoverlay, "text_sink");
......
...@@ -110,6 +110,8 @@ cleanup_videorate (GstElement * videorate) ...@@ -110,6 +110,8 @@ cleanup_videorate (GstElement * videorate)
gst_element_set_state (videorate, GST_STATE_NULL); gst_element_set_state (videorate, GST_STATE_NULL);
gst_element_get_state (videorate, NULL, NULL, GST_CLOCK_TIME_NONE); gst_element_get_state (videorate, NULL, NULL, GST_CLOCK_TIME_NONE);
gst_pad_set_active (mysrcpad, FALSE);
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_src_pad (videorate); gst_check_teardown_src_pad (videorate);
gst_check_teardown_sink_pad (videorate); gst_check_teardown_sink_pad (videorate);
gst_check_teardown_element (videorate); gst_check_teardown_element (videorate);
......
...@@ -76,6 +76,7 @@ cleanup_videotestsrc (GstElement * videotestsrc) ...@@ -76,6 +76,7 @@ cleanup_videotestsrc (GstElement * videotestsrc)
g_list_free (buffers); g_list_free (buffers);
buffers = NULL; buffers = NULL;
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_sink_pad (videotestsrc); gst_check_teardown_sink_pad (videotestsrc);
gst_check_teardown_element (videotestsrc); gst_check_teardown_element (videotestsrc);
} }
......
...@@ -96,6 +96,8 @@ cleanup_volume (GstElement * volume) ...@@ -96,6 +96,8 @@ cleanup_volume (GstElement * volume)
g_list_free (buffers); g_list_free (buffers);
buffers = NULL; buffers = NULL;
gst_pad_set_active (mysrcpad, FALSE);
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_src_pad (volume); gst_check_teardown_src_pad (volume);
gst_check_teardown_sink_pad (volume); gst_check_teardown_sink_pad (volume);
gst_check_teardown_element (volume); gst_check_teardown_element (volume);
......
...@@ -72,6 +72,8 @@ setup_vorbisdec () ...@@ -72,6 +72,8 @@ setup_vorbisdec ()
vorbisdec = gst_check_setup_element ("vorbisdec"); vorbisdec = gst_check_setup_element ("vorbisdec");
mysrcpad = gst_check_setup_src_pad (vorbisdec, &srctemplate, NULL); mysrcpad = gst_check_setup_src_pad (vorbisdec, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (vorbisdec, &sinktemplate, NULL); mysinkpad = gst_check_setup_sink_pad (vorbisdec, &sinktemplate, NULL);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);
return vorbisdec; return vorbisdec;
} }
...@@ -82,6 +84,8 @@ cleanup_vorbisdec (GstElement * vorbisdec) ...@@ -82,6 +84,8 @@ cleanup_vorbisdec (GstElement * vorbisdec)
GST_DEBUG ("cleanup_vorbisdec"); GST_DEBUG ("cleanup_vorbisdec");
gst_element_set_state (vorbisdec, GST_STATE_NULL); gst_element_set_state (vorbisdec, GST_STATE_NULL);
gst_pad_set_active (mysrcpad, FALSE);
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_src_pad (vorbisdec); gst_check_teardown_src_pad (vorbisdec);
gst_check_teardown_sink_pad (vorbisdec); gst_check_teardown_sink_pad (vorbisdec);
gst_check_teardown_element (vorbisdec); gst_check_teardown_element (vorbisdec);
......
...@@ -98,6 +98,8 @@ setup_vorbistag (void) ...@@ -98,6 +98,8 @@ setup_vorbistag (void)
vorbistag = gst_check_setup_element ("vorbistag"); vorbistag = gst_check_setup_element ("vorbistag");
mysrcpad = gst_check_setup_src_pad (vorbistag, &srctemplate, NULL); mysrcpad = gst_check_setup_src_pad (vorbistag, &srctemplate, NULL);
mysinkpad = gst_check_setup_sink_pad (vorbistag, &sinktemplate, NULL); mysinkpad = gst_check_setup_sink_pad (vorbistag, &sinktemplate, NULL);
gst_pad_set_active (mysrcpad, TRUE);
gst_pad_set_active (mysinkpad, TRUE);
return vorbistag; return vorbistag;
} }
...@@ -108,6 +110,8 @@ cleanup_vorbistag (GstElement * vorbistag) ...@@ -108,6 +110,8 @@ cleanup_vorbistag (GstElement * vorbistag)
GST_DEBUG ("cleanup_vorbistag"); GST_DEBUG ("cleanup_vorbistag");
gst_element_set_state (vorbistag, GST_STATE_NULL); gst_element_set_state (vorbistag, GST_STATE_NULL);
gst_pad_set_active (mysrcpad, FALSE);
gst_pad_set_active (mysinkpad, FALSE);
gst_check_teardown_src_pad (vorbistag); gst_check_teardown_src_pad (vorbistag);
gst_check_teardown_sink_pad (vorbistag); gst_check_teardown_sink_pad (vorbistag);
gst_check_teardown_element (vorbistag); gst_check_teardown_element (vorbistag);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment