mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-18 14:26:43 +00:00
check/generic/states.c: fix the test so that it only checks for elements that are part of this source module
Original commit message from CVS: * check/generic/states.c: (GST_START_TEST): fix the test so that it only checks for elements that are part of this source module
This commit is contained in:
parent
77c0003ad8
commit
494dc46f17
4 changed files with 91 additions and 45 deletions
|
@ -1,3 +1,9 @@
|
|||
2005-11-16 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||
|
||||
* check/generic/states.c: (GST_START_TEST):
|
||||
fix the test so that it only checks for elements that are part of
|
||||
this source module
|
||||
|
||||
2005-11-16 Michael Smith <msmith@fluendo.com>
|
||||
|
||||
* ext/ogg/gstoggmux.c: (gst_ogg_mux_clear), (gst_ogg_mux_reset),
|
||||
|
|
|
@ -20,6 +20,10 @@
|
|||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include "config.h"
|
||||
#endif
|
||||
|
||||
#include <unistd.h>
|
||||
|
||||
#include <gst/check/gstcheck.h>
|
||||
|
@ -28,14 +32,29 @@ GST_START_TEST (test_state_changes)
|
|||
{
|
||||
GstElement *element;
|
||||
GList *features, *f;
|
||||
GList *plugins, *p;
|
||||
|
||||
features = gst_registry_get_feature_list (gst_registry_get_default (),
|
||||
GST_TYPE_ELEMENT_FACTORY);
|
||||
GST_DEBUG ("testing elements from source %s", PACKAGE);
|
||||
|
||||
plugins = gst_registry_get_plugin_list (gst_registry_get_default ());
|
||||
|
||||
for (p = plugins; p; p = p->next) {
|
||||
GstPlugin *plugin = p->data;
|
||||
|
||||
if (strcmp (gst_plugin_get_source (plugin), PACKAGE) != 0)
|
||||
continue;
|
||||
|
||||
features =
|
||||
gst_registry_get_feature_list_by_plugin (gst_registry_get_default (),
|
||||
gst_plugin_get_name (plugin));
|
||||
|
||||
for (f = features; f; f = f->next) {
|
||||
GstPluginFeature *feature = f->data;
|
||||
const gchar *name = gst_plugin_feature_get_name (feature);
|
||||
|
||||
if (!GST_IS_ELEMENT_FACTORY (feature))
|
||||
continue;
|
||||
|
||||
GST_DEBUG ("testing element %s", name);
|
||||
element = gst_element_factory_make (name, name);
|
||||
if (GST_IS_PIPELINE (element)) {
|
||||
|
@ -56,6 +75,7 @@ GST_START_TEST (test_state_changes)
|
|||
gst_object_unref (GST_OBJECT (element));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
GST_END_TEST;
|
||||
|
||||
|
|
2
common
2
common
|
@ -1 +1 @@
|
|||
Subproject commit 3aa0adc0cc4539ec9bb62ccf6d535240dad19e58
|
||||
Subproject commit ea1409191cc1e71273b2dbdd94e7ab5fc5a60a51
|
|
@ -20,6 +20,10 @@
|
|||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include "config.h"
|
||||
#endif
|
||||
|
||||
#include <unistd.h>
|
||||
|
||||
#include <gst/check/gstcheck.h>
|
||||
|
@ -28,14 +32,29 @@ GST_START_TEST (test_state_changes)
|
|||
{
|
||||
GstElement *element;
|
||||
GList *features, *f;
|
||||
GList *plugins, *p;
|
||||
|
||||
features = gst_registry_get_feature_list (gst_registry_get_default (),
|
||||
GST_TYPE_ELEMENT_FACTORY);
|
||||
GST_DEBUG ("testing elements from source %s", PACKAGE);
|
||||
|
||||
plugins = gst_registry_get_plugin_list (gst_registry_get_default ());
|
||||
|
||||
for (p = plugins; p; p = p->next) {
|
||||
GstPlugin *plugin = p->data;
|
||||
|
||||
if (strcmp (gst_plugin_get_source (plugin), PACKAGE) != 0)
|
||||
continue;
|
||||
|
||||
features =
|
||||
gst_registry_get_feature_list_by_plugin (gst_registry_get_default (),
|
||||
gst_plugin_get_name (plugin));
|
||||
|
||||
for (f = features; f; f = f->next) {
|
||||
GstPluginFeature *feature = f->data;
|
||||
const gchar *name = gst_plugin_feature_get_name (feature);
|
||||
|
||||
if (!GST_IS_ELEMENT_FACTORY (feature))
|
||||
continue;
|
||||
|
||||
GST_DEBUG ("testing element %s", name);
|
||||
element = gst_element_factory_make (name, name);
|
||||
if (GST_IS_PIPELINE (element)) {
|
||||
|
@ -56,6 +75,7 @@ GST_START_TEST (test_state_changes)
|
|||
gst_object_unref (GST_OBJECT (element));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
GST_END_TEST;
|
||||
|
||||
|
|
Loading…
Reference in a new issue