MCPcopy Create free account
hub / github.com/imroc/req / testHostHeaderOverride

Function testHostHeaderOverride

request_test.go:792–796  ·  view source on GitHub ↗
(t *testing.T, c *Client)

Source from the content-addressed store, hash-verified

790}
791
792func testHostHeaderOverride(t *testing.T, c *Client) {
793 resp, err := c.R().SetHeader("Host", "testhostname").Get("/host-header")
794 assertSuccess(t, resp, err)
795 tests.AssertEqual(t, "testhostname", resp.String())
796}
797
798func assertTraceInfo(t *testing.T, resp *Response, enable bool) {
799 ti := resp.TraceInfo()

Callers

nothing calls this directly

Calls 6

AssertEqualFunction · 0.92
assertSuccessFunction · 0.85
SetHeaderMethod · 0.80
RMethod · 0.80
GetMethod · 0.45
StringMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…