tests: allow more time for the test_many_bins pipeline to preroll

Hopefully makes this test work on the OSX build bot and other
not-so-powerful machines.

https://bugzilla.gnome.org/show_bug.cgi?id=646624
This commit is contained in:
Tim-Philipp Müller 2011-04-11 12:04:34 +01:00
parent 159cf687a1
commit 6ca7284a54

View file

@ -1137,11 +1137,15 @@ GST_START_TEST (test_many_bins)
fail_unless (gst_element_link (last_bin, sink)); fail_unless (gst_element_link (last_bin, sink));
ret = gst_element_set_state (pipeline, GST_STATE_PLAYING); ret = gst_element_set_state (pipeline, GST_STATE_PLAYING);
fail_unless (ret == GST_STATE_CHANGE_ASYNC, "did not get state change async"); fail_unless_equals_int (ret, GST_STATE_CHANGE_ASYNC);
ret = gst_element_get_state (pipeline, NULL, NULL, 5 * GST_SECOND); for (i = 0; i < 15; ++i) {
fail_unless (ret == GST_STATE_CHANGE_SUCCESS, GST_INFO ("waiting for preroll ...");
"did not get state change success"); ret = gst_element_get_state (pipeline, NULL, NULL, GST_SECOND);
if (ret != GST_STATE_CHANGE_ASYNC)
break;
}
fail_unless_equals_int (ret, GST_STATE_CHANGE_SUCCESS);
gst_element_set_state (pipeline, GST_STATE_NULL); gst_element_set_state (pipeline, GST_STATE_NULL);
gst_object_unref (pipeline); gst_object_unref (pipeline);