tests: check location isn't truncated
authorLuis de Bethencourt <luis.bg@samsung.com>
Fri, 27 Mar 2015 16:23:40 +0000 (16:23 +0000)
committerLuis de Bethencourt <luis.bg@samsung.com>
Fri, 27 Mar 2015 17:19:02 +0000 (17:19 +0000)
Test covering the recent commit where location='".abc' won't get truncated
to '.ab' anymore

https://bugzilla.gnome.org/show_bug.cgi?id=688625

tests/check/elements/filesink.c

index afe06ee..9ac4f49 100644 (file)
@@ -362,6 +362,11 @@ GST_START_TEST (test_uri_interface)
   fail_unless_equals_string (location, "file:///foo/b%3Fr");
   g_free (location);
 
+  g_object_set (G_OBJECT (filesink), "location", "\".donotexist", NULL);
+  g_object_get (G_OBJECT (filesink), "location", &location, NULL);
+  fail_unless_equals_string (location, "\".donotexist");
+  g_free (location);
+
   /* should fail with other hostnames */
   fail_if (gst_uri_handler_set_uri (GST_URI_HANDLER (filesink),
           "file://hostname/foo/foo", NULL));