MCPcopy Index your code
hub / github.com/cockroachdb/errors / NewAssertionErrorWithWrappedErrf

Function NewAssertionErrorWithWrappedErrf

errutil/assertions.go:65–67  ·  view source on GitHub ↗

NewAssertionErrorWithWrappedErrf wraps an error and turns it into an assertion error. Both details from the original error and the context of the caller are preserved. The original error is not visible as cause any more. The original error message is preserved. See the doc of `AssertionFailedf()` fo

(origErr error, format string, args ...interface{})

Source from the content-addressed store, hash-verified

63// visible as cause any more. The original error message is preserved.
64// See the doc of `AssertionFailedf()` for more details.
65func NewAssertionErrorWithWrappedErrf(origErr error, format string, args ...interface{}) error {
66 return NewAssertionErrorWithWrappedErrDepthf(1, origErr, format, args...)
67}
68
69// NewAssertionErrorWithWrappedErrDepthf is like
70// NewAssertionErrorWithWrappedErrf but the depth at which the call

Callers 2

TestFormatFunction · 0.92
datadriven_test.goFile · 0.92

Tested by 1

TestFormatFunction · 0.74

Used in the wild real call sites across dependent graphs

searching dependent graphs…