tests: mountpoints: add more checks for mount point path matching

https://bugzilla.gnome.org/show_bug.cgi?id=771555
This commit is contained in:
Tim-Philipp Müller 2018-01-25 12:06:57 +00:00
parent c3e58dfdbe
commit f5b99d8fce

View file

@ -69,6 +69,9 @@ static const gchar *paths[] = {
"/tark/bar/baz",
"/tark/bar/baz/t",
"/boozop",
"/raw",
"/raw/video",
"/raw/snapshot",
};
GST_START_TEST (test_match)
@ -124,6 +127,14 @@ GST_START_TEST (test_match)
fail_unless (tmp == f[4]);
fail_unless (matched == 13);
g_object_unref (tmp);
tmp = gst_rtsp_mount_points_match (mounts, "/raw/video", &matched);
fail_unless (tmp == f[8]);
fail_unless (matched == 10);
g_object_unref (tmp);
tmp = gst_rtsp_mount_points_match (mounts, "/raw/snapshot", &matched);
fail_unless (tmp == f[9]);
fail_unless (matched == 13);
g_object_unref (tmp);
g_object_unref (mounts);
}