From f5f4aff6fe292fc843608b8e363351d12ab4c207 Mon Sep 17 00:00:00 2001 From: Mattia Lavacca Date: Fri, 19 Apr 2024 11:07:24 +0200 Subject: [PATCH] use the sharedHTTPClient Signed-off-by: Mattia Lavacca --- test/integration/test_httproute.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/test/integration/test_httproute.go b/test/integration/test_httproute.go index 7ac87ccdf..545cbc9d0 100644 --- a/test/integration/test_httproute.go +++ b/test/integration/test_httproute.go @@ -97,13 +97,11 @@ func TestHTTPRoute(t *testing.T) { waitTick = time.Second ) - httpClient := helpers.MustCreateHTTPClient(t, nil, "") - // route to /test path of service httpbin should receive a 200 OK response. request := helpers.MustBuildRequest(t, GetCtx(), http.MethodGet, "http://"+gatewayIPAddress+"/test", "") require.Eventually( t, - testutils.GetResponseBodyContains(t, clients, httpClient, request, "httpbin.org"), + testutils.GetResponseBodyContains(t, clients, sharedHTTPClient, request, "httpbin.org"), httpRouteAccessTimeout, time.Second, ) @@ -112,7 +110,7 @@ func TestHTTPRoute(t *testing.T) { request = helpers.MustBuildRequest(t, GetCtx(), http.MethodGet, "http://"+gatewayIPAddress+"/test/1234", "") require.Eventually( t, - testutils.GetResponseBodyContains(t, clients, httpClient, request, "

Not Found

"), + testutils.GetResponseBodyContains(t, clients, sharedHTTPClient, request, "

Not Found

"), httpRouteAccessTimeout, time.Second, )