MCPcopy Index your code
hub / github.com/coder/coder / TestNewIsolatedHTTPClient

Function TestNewIsolatedHTTPClient

coderd/coderdtest/httpclient_test.go:16–26  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

14)
15
16func TestNewIsolatedHTTPClient(t *testing.T) {
17 t.Parallel()
18
19 client := coderdtest.NewIsolatedHTTPClient(testutil.MustURL(t, "http://example.com"))
20 require.NotNil(t, client.Transport)
21 require.NotSame(t, http.DefaultTransport, client.Transport)
22
23 transport, ok := client.Transport.(*http.Transport)
24 require.True(t, ok)
25 require.Nil(t, transport.TLSClientConfig)
26}
27
28func TestNewIsolatedHTTPSClient(t *testing.T) {
29 t.Parallel()

Callers

nothing calls this directly

Calls 2

NewIsolatedHTTPClientFunction · 0.92
MustURLFunction · 0.92

Tested by

no test coverage detected