Update require.go.tmpl

Co-authored-by: Olivier Mengué <dolmen@cpan.org>
pull/1610/head
Simon Schulte 2024-06-13 15:40:29 +02:00 committed by GitHub
parent 9326036bf5
commit 044c46a89f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -1,5 +1,5 @@
{{ replace .Comment "assert." "require."}}
// Instead of returning a boolean result this function calls `t.FailNow()` on failure.
// Failure of this check is fatal ([testing.T.FailNow] is called on failure).
func {{.DocInfo.Name}}(t TestingT, {{.Params}}) {
if h, ok := t.(tHelper); ok { h.Helper() }
if assert.{{.DocInfo.Name}}(t, {{.ForwardedParams}}) { return }