MCPcopy
hub / github.com/cli/cli / ReplaceTripper

Function ReplaceTripper

pkg/httpmock/registry.go:14–16  ·  view source on GitHub ↗

Replace http.Client transport layer with registry so all requests get recorded.

(client *http.Client, reg *Registry)

Source from the content-addressed store, hash-verified

12// Replace http.Client transport layer with registry so all requests get
13// recorded.
14func ReplaceTripper(client *http.Client, reg *Registry) {
15 client.Transport = reg
16}
17
18type Registry struct {
19 mu sync.Mutex

Callers 15

newTestDiscussionClientFunction · 0.92
TestIssueListFunction · 0.92
TestIssueList_paginationFunction · 0.92
TestNewTrustedRootCmdFunction · 0.92
TestGetTrustedRootFunction · 0.92
TestNewVerifyCmdFunction · 0.92
TestIssueFeaturesFunction · 0.92
TestPullRequestFeaturesFunction · 0.92
TestRepositoryFeaturesFunction · 0.92
TestProjectV1SupportFunction · 0.92

Calls

no outgoing calls

Tested by 15

newTestDiscussionClientFunction · 0.74
TestIssueListFunction · 0.74
TestIssueList_paginationFunction · 0.74
TestNewTrustedRootCmdFunction · 0.74
TestGetTrustedRootFunction · 0.74
TestNewVerifyCmdFunction · 0.74
TestIssueFeaturesFunction · 0.74
TestPullRequestFeaturesFunction · 0.74
TestRepositoryFeaturesFunction · 0.74
TestProjectV1SupportFunction · 0.74