MCPcopy Index your code
hub / github.com/google/go-github / TestBasicAuthTransport_transport

Function TestBasicAuthTransport_transport

github/github_test.go:4116–4131  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

4114}
4115
4116func TestBasicAuthTransport_transport(t *testing.T) {
4117 t.Parallel()
4118 // default transport
4119 tp := &BasicAuthTransport{}
4120 if tp.transport() != http.DefaultTransport {
4121 t.Error("Expected http.DefaultTransport to be used.")
4122 }
4123
4124 // custom transport
4125 tp = &BasicAuthTransport{
4126 Transport: &http.Transport{},
4127 }
4128 if tp.transport() == http.DefaultTransport {
4129 t.Error("Expected custom transport to be used.")
4130 }
4131}
4132
4133func TestFormatRateReset(t *testing.T) {
4134 t.Parallel()

Callers

nothing calls this directly

Calls 2

transportMethod · 0.95
ErrorMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…