From 4b84d7552f29888a9deadc329cc7b88d7226d13f Mon Sep 17 00:00:00 2001 From: Jan Schmidt Date: Thu, 15 Oct 2009 10:28:39 +0100 Subject: [PATCH] check: Don't fail the basetime test when no audiosrc is available On OS/X the DEFAULT_AUDIOSRC is not going to be available, because it isn't in gst-plugins-base. Just defer the test, instead of failing it. --- tests/check/pipelines/basetime.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/tests/check/pipelines/basetime.c b/tests/check/pipelines/basetime.c index 6fc1a60eef..00072ef012 100644 --- a/tests/check/pipelines/basetime.c +++ b/tests/check/pipelines/basetime.c @@ -67,9 +67,17 @@ GST_START_TEST (test_basetime_calculation) fail_if (p1 == NULL); /* Create a sub-bin that is activated only in "certain situations" */ - bin = gst_bin_new ("audiobin"); asrc = gst_element_factory_make (DEFAULT_AUDIOSRC, NULL); + if (asrc == NULL) { + GST_WARNING ("Cannot run test. test audio source %s not available", + DEFAULT_AUDIOSRC); + gst_element_set_state (p1, GST_STATE_NULL); + gst_object_unref (p1); + return; + } asink = gst_element_factory_make ("fakesink", NULL); + + bin = gst_bin_new ("audiobin"); gst_bin_add_many (GST_BIN (bin), asrc, asink, NULL); gst_element_link (asrc, asink);