Skip to content

Commit

Permalink
Review: Expand NotErrorAs func docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Pål Sivertsen committed Oct 4, 2024
1 parent dc100b1 commit f844b26
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 8 deletions.
3 changes: 2 additions & 1 deletion assert/assertion_format.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions assert/assertion_forward.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion assert/assertions.go
Original file line number Diff line number Diff line change
Expand Up @@ -2149,7 +2149,8 @@ func ErrorAs(t TestingT, err error, target interface{}, msgAndArgs ...interface{
), msgAndArgs...)
}

// NotErrorAs asserts that none of the errors in err's chain matches target.
// NotErrorAs asserts that none of the errors in err's chain matches target,
// but if so, sets target to that error value.
func NotErrorAs(t TestingT, err error, target interface{}, msgAndArgs ...interface{}) bool {
if h, ok := t.(tHelper); ok {
h.Helper()
Expand Down
6 changes: 4 additions & 2 deletions require/require.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions require/require_forward.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit f844b26

Please sign in to comment.