[vlc-commits] url: improve URL query parameter tests

Rémi Denis-Courmont git at videolan.org
Thu Aug 27 20:38:20 CEST 2015


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Aug 27 19:28:21 2015 +0300| [1a31763e3cef6276eb537ca106b404b2ff9057f5] | committer: Rémi Denis-Courmont

url: improve URL query parameter tests

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=1a31763e3cef6276eb537ca106b404b2ff9057f5
---

 src/test/url.c |    4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/test/url.c b/src/test/url.c
index 8b041d0..f1fa69a 100644
--- a/src/test/url.c
+++ b/src/test/url.c
@@ -191,6 +191,10 @@ int main (void)
     test_url_parse("protocol://john:doe@1.2.3.4:567", "protocol", "john", "doe", "1.2.3.4", 567, NULL, NULL);
     test_url_parse("http://a.b/?opt=val", "http", NULL, NULL, "a.b", 0, "/", "opt=val");
     test_url_parse("p://u:p@host:123/a/b/c?o=v", "p", "u", "p", "host", 123, "/a/b/c", "o=v");
+    test_url_parse("p://?o=v", "p", NULL, NULL, "", 0, NULL, "o=v");
+    test_url_parse("p://h?o=v", "p", NULL, NULL, "h", 0, NULL, "o=v");
+    test_url_parse("p://h:123?o=v", "p", NULL, NULL, "h", 123, NULL, "o=v");
+    test_url_parse("p://u:p@h:123?o=v", "p", "u", "p", "h", 123, NULL, "o=v");
 
     return 0;
 }



More information about the vlc-commits mailing list