MCPcopy Create free account
hub / github.com/ProspectOne/perfops-cli / reqBody

Function reqBody

cmd/root_test.go:231–242  ·  view source on GitHub ↗
(req *http.Request)

Source from the content-addressed store, hash-verified

229}
230
231func reqBody(req *http.Request) string {
232 if req == nil || req.Body == nil {
233 return ""
234 }
235
236 defer req.Body.Close()
237 b, err := ioutil.ReadAll(req.Body)
238 if err != nil {
239 return ""
240 }
241 return string(bytes.TrimSpace(b))
242}

Callers 7

TestRunLatencyFunction · 0.70
TestRunMTRFunction · 0.70
TestRunDNSPerfFunction · 0.70
TestRunDNSResolveFunction · 0.70
TestRunCurlResolveFunction · 0.70
TestRunTracerouteFunction · 0.70
TestRunPingFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected