From 82c356f2548ca62b75f76104bef44915482e8fd9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Dunglas?= Date: Mon, 2 Oct 2023 22:55:09 +0200 Subject: fix: caddytest.AssertResponseCode error message (#5853) --- caddytest/caddytest.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'caddytest') diff --git a/caddytest/caddytest.go b/caddytest/caddytest.go index 9c17070..39aca23 100644 --- a/caddytest/caddytest.go +++ b/caddytest/caddytest.go @@ -467,7 +467,7 @@ func (tc *Tester) AssertResponseCode(req *http.Request, expectedStatusCode int) } if expectedStatusCode != resp.StatusCode { - tc.t.Errorf("requesting \"%s\" expected status code: %d but got %d", req.RequestURI, expectedStatusCode, resp.StatusCode) + tc.t.Errorf("requesting \"%s\" expected status code: %d but got %d", req.URL.RequestURI(), expectedStatusCode, resp.StatusCode) } return resp -- cgit v1.2.3