MCPcopy
hub / github.com/cli/cli / newTestClient

Function newTestClient

api/client_test.go:16–20  ·  view source on GitHub ↗
(reg *httpmock.Registry)

Source from the content-addressed store, hash-verified

14)
15
16func newTestClient(reg *httpmock.Registry) *Client {
17 client := &http.Client{}
18 httpmock.ReplaceTripper(client, reg)
19 return NewClientFromHTTP(client)
20}
21
22func TestGraphQL(t *testing.T) {
23 http := &httpmock.Registry{}

Calls 2

ReplaceTripperFunction · 0.92
NewClientFromHTTPFunction · 0.85

Tested by

no test coverage detected