Skip to content

Commit

Permalink
internal/proxy/proxytest: use standard transport
Browse files Browse the repository at this point in the history
proxytest is just used for tests so we don't need opencensus. Remove
the transport and the dependency.

For golang/go#61399

Change-Id: If2ef831deb098c393e625fdc288a8f6015540b48
Reviewed-on: https://go-review.googlesource.com/c/pkgsite/+/550875
Reviewed-by: Jonathan Amsterdam <[email protected]>
LUCI-TryBot-Result: Go LUCI <[email protected]>
TryBot-Bypass: Michael Matloob <[email protected]>
  • Loading branch information
matloob committed Dec 18, 2023
1 parent 8d0563a commit b2a01f8
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions internal/proxy/proxytest/proxytest.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import (
"strings"
"testing"

"go.opencensus.io/plugin/ochttp"
"golang.org/x/mod/modfile"
"golang.org/x/pkgsite/internal/proxy"
"golang.org/x/pkgsite/internal/testing/testhelper"
Expand All @@ -37,7 +36,7 @@ func SetupTestClient(t *testing.T, modules []*Module) (*proxy.Client, func()) {
func NewClientForServer(s *Server) (*proxy.Client, func(), error) {
// override client.httpClient to skip TLS verification
httpClient, prox, serverClose := testhelper.SetupTestClientAndServer(s.mux)
client, err := proxy.New(prox.URL, new(ochttp.Transport))
client, err := proxy.New(prox.URL, nil)
if err != nil {
return nil, nil, err
}
Expand Down

0 comments on commit b2a01f8

Please sign in to comment.