MCPcopy Index your code
hub / github.com/cloudflare/cloudflared / headerToReqHeader

Function headerToReqHeader

connection/header_test.go:72–80  ·  view source on GitHub ↗
(headers http.Header)

Source from the content-addressed store, hash-verified

70}
71
72func headerToReqHeader(headers http.Header) (reqHeaders []HTTPHeader) {
73 for name, values := range headers {
74 for _, value := range values {
75 reqHeaders = append(reqHeaders, HTTPHeader{Name: name, Value: value})
76 }
77 }
78
79 return reqHeaders
80}
81
82func TestSerializeNoHeaders(t *testing.T) {
83 request, err := http.NewRequest(http.MethodGet, "http://example.com", nil)

Callers 1

TestSerializeHeadersFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected