From 4fd4e8a16e243d48b975bd3449b715a5e64de5ea Mon Sep 17 00:00:00 2001 From: Jakub Date: Thu, 5 Jan 2023 16:47:03 +0100 Subject: [PATCH] GODT-2181: Add env proxy support for integration tests. --- tests/api_test.go | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/tests/api_test.go b/tests/api_test.go index 1d00122e..0f9b0bca 100644 --- a/tests/api_test.go +++ b/tests/api_test.go @@ -18,6 +18,8 @@ package tests import ( + "crypto/tls" + "net/http" "net/url" "os" @@ -72,7 +74,13 @@ func newLiveAPI(hostURL string) API { } return &liveAPI{ - Server: server.New(server.WithProxyOrigin(hostURL)), + Server: server.New( + server.WithProxyOrigin(hostURL), + server.WithProxyTransport(&http.Transport{ + TLSClientConfig: &tls.Config{InsecureSkipVerify: true}, + Proxy: http.ProxyFromEnvironment, + }), + ), domain: url.Hostname(), } }