Skip to content

Commit

Permalink
fix: remove assert code when result param is empty
Browse files Browse the repository at this point in the history
fix: remove verbose blank line

fix: error
tr1v3r committed Jan 16, 2024
1 parent 9c187af commit 706976e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/template/method.go
Original file line number Diff line number Diff line change
@@ -421,8 +421,8 @@ func Test_{{.TargetStruct}}_{{.MethodName}}(t *testing.T) {
for i, tt := range {{.OriginStruct.Type}}{{.MethodName}}TestCase {
t.Run("{{.MethodName}}_"+strconv.Itoa(i), func(t *testing.T) {
{{.GetTestResultParamInTmpl}} := do.{{.MethodName}}({{.GetTestParamInTmpl}})
{{.GetAssertInTmpl}}
{{if .GetTestResultParamInTmpl}}{{.GetTestResultParamInTmpl}} := do.{{.MethodName}}({{.GetTestParamInTmpl}})
{{.GetAssertInTmpl}}{{else}}do.{{.MethodName}}({{.GetTestParamInTmpl}}){{end}}
})
}
}

0 comments on commit 706976e

Please sign in to comment.