summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim@centricular.com>2018-01-20 15:49:35 +0000
committerTim-Philipp Müller <tim@centricular.com>2018-01-20 15:49:35 +0000
commit92400a3b695ca0aad107a1be46963993ec80215b (patch)
tree8befbfec9da1c8b6323478f0669e9a1a219c31dd /tests
parente62eb34bfc08115c8125355152f55436ea6db506 (diff)
tests: camerabin: skip checks if we don't have encoders for the default format
https://bugzilla.gnome.org/show_bug.cgi?id=767863
Diffstat (limited to 'tests')
-rw-r--r--tests/check/elements/camerabin.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/tests/check/elements/camerabin.c b/tests/check/elements/camerabin.c
index e554b0b73..f7ae8e028 100644
--- a/tests/check/elements/camerabin.c
+++ b/tests/check/elements/camerabin.c
@@ -1921,15 +1921,18 @@ TestCaseDef tests[] = {
static Suite *
camerabin_suite (void)
{
- GstElementFactory *jpegenc_factory;
+ GstRegistry *reg = gst_registry_get ();
Suite *s = suite_create ("camerabin");
gint i;
TCase *tc_generic = tcase_create ("generic");
TCase *tc_phography_iface = tcase_create ("photography-iface");
- jpegenc_factory = gst_element_factory_find ("jpegenc");
- if (jpegenc_factory == NULL) {
- GST_WARNING ("Skipping camerabin tests because jpegenc is missing");
+ if (!gst_registry_check_feature_version (reg, "jpegenc", 1, 0, 0)
+ || !gst_registry_check_feature_version (reg, "theoraenc", 1, 0, 0)
+ || !gst_registry_check_feature_version (reg, "vorbisenc", 1, 0, 0)
+ || !gst_registry_check_feature_version (reg, "oggmux", 1, 0, 0)) {
+ GST_WARNING ("Skipping camerabin tests because some required element is "
+ " missing (jpegenc, theoraenc, vorbisenc, oggmux)");
goto end;
}