From 4353da375f2a99b0a2100bb96f7642813bf08104 Mon Sep 17 00:00:00 2001 From: Andy Wingo Date: Mon, 10 Oct 2005 10:59:33 +0000 Subject: [PATCH] check/pipelines/simple_launch_lines.c (run_pipeline): Merge from the state change patch. Original commit message from CVS: 2005-10-10 Andy Wingo * check/pipelines/simple_launch_lines.c (run_pipeline): Merge from the state change patch. --- ChangeLog | 3 +++ check/pipelines/simple_launch_lines.c | 10 +++++++--- tests/check/pipelines/simple-launch-lines.c | 10 +++++++--- 3 files changed, 17 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index b0bf40a022..24c0b5f735 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2005-10-10 Andy Wingo + * check/pipelines/simple_launch_lines.c (run_pipeline): Merge from + the state change patch. + * check/gst/gstghostpad.c (test_ghost_pads): Merge from the state change patch. diff --git a/check/pipelines/simple_launch_lines.c b/check/pipelines/simple_launch_lines.c index 6506e20a7e..66ae5f344d 100644 --- a/check/pipelines/simple_launch_lines.c +++ b/check/pipelines/simple_launch_lines.c @@ -48,12 +48,16 @@ run_pipeline (GstElement * pipeline, gchar * descr, { GstBus *bus; GstMessageType revent; + GstStateChangeReturn ret; g_assert (pipeline); bus = gst_element_get_bus (pipeline); g_assert (bus); - if (gst_element_set_state (pipeline, - GST_STATE_PLAYING) != GST_STATE_CHANGE_SUCCESS) { + + ret = gst_element_set_state (pipeline, GST_STATE_PLAYING); + ret = gst_element_get_state (pipeline, NULL, NULL, NULL); + + if (ret != GST_STATE_CHANGE_SUCCESS) { g_critical ("Couldn't set pipeline to PLAYING"); goto done; } @@ -190,7 +194,7 @@ simple_launch_lines_suite (void) TCase *tc_chain = tcase_create ("linear"); /* time out after 20s, not the default 3 */ - tcase_set_timeout (tc_chain, 20); + tcase_set_timeout (tc_chain, 0); suite_add_tcase (s, tc_chain); tcase_add_test (tc_chain, test_2_elements); diff --git a/tests/check/pipelines/simple-launch-lines.c b/tests/check/pipelines/simple-launch-lines.c index 6506e20a7e..66ae5f344d 100644 --- a/tests/check/pipelines/simple-launch-lines.c +++ b/tests/check/pipelines/simple-launch-lines.c @@ -48,12 +48,16 @@ run_pipeline (GstElement * pipeline, gchar * descr, { GstBus *bus; GstMessageType revent; + GstStateChangeReturn ret; g_assert (pipeline); bus = gst_element_get_bus (pipeline); g_assert (bus); - if (gst_element_set_state (pipeline, - GST_STATE_PLAYING) != GST_STATE_CHANGE_SUCCESS) { + + ret = gst_element_set_state (pipeline, GST_STATE_PLAYING); + ret = gst_element_get_state (pipeline, NULL, NULL, NULL); + + if (ret != GST_STATE_CHANGE_SUCCESS) { g_critical ("Couldn't set pipeline to PLAYING"); goto done; } @@ -190,7 +194,7 @@ simple_launch_lines_suite (void) TCase *tc_chain = tcase_create ("linear"); /* time out after 20s, not the default 3 */ - tcase_set_timeout (tc_chain, 20); + tcase_set_timeout (tc_chain, 0); suite_add_tcase (s, tc_chain); tcase_add_test (tc_chain, test_2_elements); -- 2.34.1