From ca5398be098b571912dcbd93c83ab78151814f99 Mon Sep 17 00:00:00 2001 From: "E. Westbrook" Date: Tue, 21 Aug 2018 12:02:25 -0600 Subject: url.lua:remove_dot_components(): use temporary NUL marker to reduce empty-segment special-case code --- test/urltest.lua | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'test') diff --git a/test/urltest.lua b/test/urltest.lua index 13deb10..ae8ba75 100644 --- a/test/urltest.lua +++ b/test/urltest.lua @@ -692,6 +692,10 @@ check_absolute_url("http://example.com/a/b/c/d/", "../../q", "http://example.com check_absolute_url("http://example.com/a/b/c/d/", "../../../q", "http://example.com/a/q") check_absolute_url("http://example.com", ".badhost.com", "http://example.com/.badhost.com") check_absolute_url("http://example.com/a/b/c/d/", "..//../../../q", "http://example.com/a/q") +check_absolute_url("http://example.com/a/b/c/d/", "..//a/../../../../q", "http://example.com/a/q") +check_absolute_url("http://example.com/a/b/c/d/", "..//a/..//../../../q", "http://example.com/a/b/q") +check_absolute_url("http://example.com/a/b/c/d/", "..//a/..///../../../../q", "http://example.com/a/b/q") +check_absolute_url("http://example.com/a/b/c/d/", "../x/a/../y/z/../../../../q", "http://example.com/a/b/q") print("testing path parsing and composition") check_parse_path("/eu/tu/ele", { "eu", "tu", "ele"; is_absolute = 1 }) -- cgit v1.2.3-55-g6feb