MCPcopy
hub / github.com/stretchr/testify / HTTPSuccessf

Method HTTPSuccessf

assert/assertion_forward.go:678–683  ·  view source on GitHub ↗

HTTPSuccessf asserts that a specified handler returns a success status code. a.HTTPSuccessf(myHandler, "POST", "http://www.google.com", nil, "error message %s", "formatted") Returns whether the assertion was successful (true) or not (false).

(handler http.HandlerFunc, method string, url string, values url.Values, msg string, args ...interface{})

Source from the content-addressed store, hash-verified

676//
677// Returns whether the assertion was successful (true) or not (false).
678func (a *Assertions) HTTPSuccessf(handler http.HandlerFunc, method string, url string, values url.Values, msg string, args ...interface{}) bool {
679 if h, ok := a.t.(tHelper); ok {
680 h.Helper()
681 }
682 return HTTPSuccessf(a.t, handler, method, url, values, msg, args...)
683}
684
685// Implements asserts that an object is implemented by the specified interface.
686//

Callers

nothing calls this directly

Calls 2

HTTPSuccessfFunction · 0.70
HelperMethod · 0.65

Tested by

no test coverage detected