Skip to content

Commit

Permalink
fix calling Validate method
Browse files Browse the repository at this point in the history
  • Loading branch information
shogo82148 committed Feb 21, 2022
1 parent 0d8de48 commit 1769c5f
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion goagen/codegen/validation_test.go
Expand Up @@ -442,7 +442,16 @@ const (

utCode = ` if val.Foo == nil {
err = goa.MergeErrors(err, goa.MissingAttributeError(` + "`context`" + `, "foo"))
}
if val.Foo2 != nil {
if err2 := val.Foo2.Validate(); err2 != nil {
err = goa.MergeErrors(err, err2)
}
}`

utRequiredCode = ``
utRequiredCode = ` if val.Foo2 != nil {
if err2 := val.Foo2.Validate(); err2 != nil {
err = goa.MergeErrors(err, err2)
}
}`
)

0 comments on commit 1769c5f

Please sign in to comment.