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

Function ErrorIsf

assert/assertion_format.go:161–166  ·  view source on GitHub ↗

ErrorIsf asserts that at least one of the errors in err's chain matches target. This is a wrapper for errors.Is.

(t TestingT, err error, target error, msg string, args ...interface{})

Source from the content-addressed store, hash-verified

159// ErrorIsf asserts that at least one of the errors in err's chain matches target.
160// This is a wrapper for errors.Is.
161func ErrorIsf(t TestingT, err error, target error, msg string, args ...interface{}) bool {
162 if h, ok := t.(tHelper); ok {
163 h.Helper()
164 }
165 return ErrorIs(t, err, target, append([]interface{}{msg}, args...)...)
166}
167
168// Eventuallyf asserts that given condition will be met in waitFor time,
169// periodically checking target function each tick.

Callers 2

ErrorIsfFunction · 0.92
ErrorIsfMethod · 0.70

Calls 2

ErrorIsFunction · 0.70
HelperMethod · 0.65

Tested by

no test coverage detected