MCPcopy
hub / github.com/dapr/dapr / HTTP

Function HTTP

tests/integration/framework/client/http.go:27–29  ·  view source on GitHub ↗

HTTP returns a Go http.Client which has a default timeout of 10 seconds, and separate connection pool to the default allowing tests to be properly isolated when running in parallel. The returned client will call CloseIdleConnections on test cleanup.

(t assert.TestingT)

Source from the content-addressed store, hash-verified

25// isolated when running in parallel.
26// The returned client will call CloseIdleConnections on test cleanup.
27func HTTP(t assert.TestingT) *http.Client {
28 return HTTPWithTimeout(t, time.Second*30)
29}
30
31func HTTPWithTimeout(t assert.TestingT, timeout time.Duration) *http.Client {
32 client := &http.Client{

Callers 15

RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92
RunMethod · 0.92

Calls 1

HTTPWithTimeoutFunction · 0.85

Tested by

no test coverage detected