From ce49e7d867341ac4d243c8d7b51460b8c110511f Mon Sep 17 00:00:00 2001 From: Vasiliy Tolstov Date: Sat, 6 Feb 2021 19:05:55 +0300 Subject: [PATCH] extend test case Signed-off-by: Vasiliy Tolstov --- http_test.go | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/http_test.go b/http_test.go index 3c13127..1518ab5 100644 --- a/http_test.go +++ b/http_test.go @@ -1,6 +1,8 @@ package http import ( + "net/url" + "strings" "testing" ) @@ -17,7 +19,15 @@ func TestValidPath(t *testing.T) { if err != nil { t.Fatal(err) } - _, _ = p, m + u, err := url.Parse(p) + if err != nil { + t.Fatal(err) + } + _ = m + parts := strings.Split(u.RawQuery, "&") + if len(parts) != 3 { + t.Fatalf("invalid path: %v", parts) + } } func TestInvalidPath(t *testing.T) {