MCPcopy Create free account
hub / github.com/expr-lang/expr / NoErrorf

Method NoErrorf

internal/testify/assert/assertion_forward.go:1080–1085  ·  view source on GitHub ↗

NoErrorf asserts that a function returned no error (i.e. `nil`). actualObj, err := SomeFunction() if a.NoErrorf(err, "error message %s", "formatted") { assert.Equal(t, expectedObj, actualObj) }

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

Source from the content-addressed store, hash-verified

1078// assert.Equal(t, expectedObj, actualObj)
1079// }
1080func (a *Assertions) NoErrorf(err error, msg string, args ...interface{}) bool {
1081 if h, ok := a.t.(tHelper); ok {
1082 h.Helper()
1083 }
1084 return NoErrorf(a.t, err, msg, args...)
1085}
1086
1087// NoFileExists checks whether a file does not exist in a given path. It fails
1088// if the path points to an existing _file_ only.

Callers

nothing calls this directly

Calls 2

NoErrorfFunction · 0.70
HelperMethod · 0.45

Tested by

no test coverage detected