Skip to content

Commit

Permalink
feat: add newline between import groups
Browse files Browse the repository at this point in the history
I've adjusted the template to add a newline between the Kelpie imports and the imports required by the mock to make it easier to understand where they come from when reading the generated code.
  • Loading branch information
adamconnelly committed Jun 2, 2024
1 parent 5e909db commit 7b5adb1
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cmd/kelpie/mock.go.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,11 @@ package {{ .PackageName }}
import (
"github.com/adamconnelly/kelpie"
"github.com/adamconnelly/kelpie/mocking"
{{- range $i := .Imports }}
{{- with .Imports }}
{{ range $i := . }}
{{ $i }}
{{- end }}
{{- end }}
)

type Mock struct {
Expand Down
1 change: 1 addition & 0 deletions examples/mocks/requester/requester.go

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

1 change: 1 addition & 0 deletions examples/users/mocks/userrepository/userrepository.go

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

0 comments on commit 7b5adb1

Please sign in to comment.