summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Kost <ensonic@users.sourceforge.net>2008-10-06 15:53:01 +0000
committerStefan Kost <ensonic@users.sourceforge.net>2008-10-06 15:53:01 +0000
commit11450de6779ef2cead6767f87ce91770cd453e46 (patch)
tree1d3dc24a58722f91e26e25aaea5d70c45406fbcf
parentc3e91e1a880e99201cecc8aae65256a39ce3ab4e (diff)
tests/check/generic/states.c: Stop test on state-change error. Should be applied on other modules if we agree that it...
Original commit message from CVS: * tests/check/generic/states.c: Stop test on state-change error. Should be applied on other modules if we agree that it makes sense.
-rw-r--r--ChangeLog14
-rw-r--r--tests/check/generic/states.c73
2 files changed, 55 insertions, 32 deletions
diff --git a/ChangeLog b/ChangeLog
index cfe3d65aa..f273020e0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2008-10-06 Stefan Kost <ensonic@users.sf.net>
+
+ * tests/check/generic/states.c:
+ Stop test on state-change error. Should be applied on other modules if
+ we agree that it makes sense.
+
2008-10-06 Zaheer Abbas Merali <zaheerabbas at merali dot org>
* gst/mpegtsparse/mpegtsparse.c:
@@ -25,6 +31,14 @@
2008-10-03 Stefan Kost <ensonic@users.sf.net>
+ * ext/metadata/README:
+ * ext/metadata/metadataexif.c:
+ * ext/metadata/metadatatags.c:
+ * ext/metadata/metadatatags.h:
+ Use core gps tags.
+
+2008-10-03 Stefan Kost <ensonic@users.sf.net>
+
* ext/metadata/metadata_mapping.htm:
* ext/metadata/metadataxmp.c:
* ext/metadata/Makefile.am:
diff --git a/tests/check/generic/states.c b/tests/check/generic/states.c
index 6b5ab9906..f5c9d0edd 100644
--- a/tests/check/generic/states.c
+++ b/tests/check/generic/states.c
@@ -103,6 +103,7 @@ teardown ()
GST_START_TEST (test_state_changes_up_and_down_seq)
{
GstElement *element;
+ GstStateChangeReturn sret;
GList *e;
for (e = elements; e; e = e->next) {
@@ -116,17 +117,20 @@ GST_START_TEST (test_state_changes_up_and_down_seq)
GST_DEBUG ("element %s is a pipeline", name);
}
- gst_element_set_state (element, GST_STATE_READY);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_PLAYING);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_READY);
- gst_element_set_state (element, GST_STATE_NULL);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_READY);
- gst_element_set_state (element, GST_STATE_PLAYING);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_NULL);
+ sret = gst_element_set_state (element, GST_STATE_READY);
+ if (sret != GST_STATE_CHANGE_FAILURE) {
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_PLAYING);
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_READY);
+ gst_element_set_state (element, GST_STATE_NULL);
+
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_READY);
+ gst_element_set_state (element, GST_STATE_PLAYING);
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_NULL);
+ }
gst_object_unref (GST_OBJECT (element));
}
}
@@ -136,6 +140,7 @@ GST_END_TEST;
GST_START_TEST (test_state_changes_up_seq)
{
GstElement *element;
+ GstStateChangeReturn sret;
GList *e;
for (e = elements; e; e = e->next) {
@@ -149,17 +154,18 @@ GST_START_TEST (test_state_changes_up_seq)
GST_DEBUG ("element %s is a pipeline", name);
}
- gst_element_set_state (element, GST_STATE_READY);
-
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_READY);
+ sret = gst_element_set_state (element, GST_STATE_READY);
+ if (sret != GST_STATE_CHANGE_FAILURE) {
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_READY);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_PLAYING);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_READY);
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_PLAYING);
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_READY);
- gst_element_set_state (element, GST_STATE_NULL);
+ gst_element_set_state (element, GST_STATE_NULL);
+ }
gst_object_unref (GST_OBJECT (element));
}
}
@@ -169,6 +175,7 @@ GST_END_TEST;
GST_START_TEST (test_state_changes_down_seq)
{
GstElement *element;
+ GstStateChangeReturn sret;
GList *e;
for (e = elements; e; e = e->next) {
@@ -182,21 +189,23 @@ GST_START_TEST (test_state_changes_down_seq)
GST_DEBUG ("element %s is a pipeline", name);
}
- gst_element_set_state (element, GST_STATE_READY);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_PLAYING);
+ sret = gst_element_set_state (element, GST_STATE_READY);
+ if (sret != GST_STATE_CHANGE_FAILURE) {
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_PLAYING);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_PLAYING);
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_PLAYING);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_READY);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_PLAYING);
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_READY);
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_PLAYING);
- gst_element_set_state (element, GST_STATE_PAUSED);
- gst_element_set_state (element, GST_STATE_READY);
- gst_element_set_state (element, GST_STATE_NULL);
+ gst_element_set_state (element, GST_STATE_PAUSED);
+ gst_element_set_state (element, GST_STATE_READY);
+ gst_element_set_state (element, GST_STATE_NULL);
+ }
gst_object_unref (GST_OBJECT (element));
}
}