[gst-cvs] gst-plugins-good: deinterlace: Adds basic check test
Thiago Sousa Santos
thiagoss at kemper.freedesktop.org
Tue Jan 5 14:05:16 PST 2010
Module: gst-plugins-good
Branch: master
Commit: 2370c452cafa7b4132d30a77dff6a76e9623af82
URL: http://cgit.freedesktop.org/gstreamer/gst-plugins-good/commit/?id=2370c452cafa7b4132d30a77dff6a76e9623af82
Author: Thiago Santos <thiago.sousa.santos at collabora.co.uk>
Date: Mon Jan 4 13:43:00 2010 -0300
deinterlace: Adds basic check test
Adds a basic check test for deinterlace element
---
tests/check/Makefile.am | 1 +
tests/check/elements/deinterlace.c | 53 ++++++++++++++++++++++++++++++++++++
2 files changed, 54 insertions(+), 0 deletions(-)
diff --git a/tests/check/Makefile.am b/tests/check/Makefile.am
index 065d226..37a9b28 100644
--- a/tests/check/Makefile.am
+++ b/tests/check/Makefile.am
@@ -98,6 +98,7 @@ check_PROGRAMS = \
elements/audiowsinclimit \
elements/avimux \
elements/avisubtitle \
+ elements/deinterlace \
elements/deinterleave \
elements/equalizer \
elements/flvdemux \
diff --git a/tests/check/elements/deinterlace.c b/tests/check/elements/deinterlace.c
new file mode 100644
index 0000000..5a6ff7b
--- /dev/null
+++ b/tests/check/elements/deinterlace.c
@@ -0,0 +1,53 @@
+/* GStreamer unit tests for the deinterlace element
+ * Copyright (C) 2010 Thiago Santos <thiago.sousa.santos at collabora.co.uk>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+#ifdef HAVE_CONFIG_H
+# include "config.h"
+#endif
+
+#include <stdio.h>
+#include <gst/check/gstcheck.h>
+
+GST_START_TEST (test_create_and_unref)
+{
+ GstElement *deinterlace;
+
+ deinterlace = gst_element_factory_make ("deinterlace", NULL);
+ fail_unless (deinterlace != NULL);
+
+ gst_element_set_state (deinterlace, GST_STATE_NULL);
+ gst_object_unref (deinterlace);
+}
+
+GST_END_TEST;
+
+static Suite *
+deinterlace_suite (void)
+{
+ Suite *s = suite_create ("deinterlace");
+ TCase *tc_chain = tcase_create ("general");
+
+ suite_add_tcase (s, tc_chain);
+ tcase_set_timeout (tc_chain, 180);
+ tcase_add_test (tc_chain, test_create_and_unref);
+
+ return s;
+}
+
+GST_CHECK_MAIN (deinterlace);
More information about the Gstreamer-commits
mailing list