From 136b0e9681b91e472056f3144abf3186fa9ede86 Mon Sep 17 00:00:00 2001 From: Justin Alvarez Date: Fri, 20 Oct 2023 13:11:33 -0400 Subject: [PATCH] fix test Signed-off-by: Justin Alvarez --- cmd/finch/doc.TEMPLATE | 4 ++-- cmd/finch/gen_docs_test.go | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/cmd/finch/doc.TEMPLATE b/cmd/finch/doc.TEMPLATE index af7477d63..6aa00844f 100644 --- a/cmd/finch/doc.TEMPLATE +++ b/cmd/finch/doc.TEMPLATE @@ -2,9 +2,9 @@ title: "{{ .CmdPath }}" --- -## {{ .CmdPath }}{{if gt (len .Description) 0}} +## {{ .CmdPath }} -{{ .Description }} +{{if gt (len .Description) 0}}{{ .Description }} {{end}}{{if gt (len .Properties) 0}}### Properties diff --git a/cmd/finch/gen_docs_test.go b/cmd/finch/gen_docs_test.go index 9429804b0..bf595f735 100644 --- a/cmd/finch/gen_docs_test.go +++ b/cmd/finch/gen_docs_test.go @@ -96,9 +96,10 @@ func TestGenDocsAction_runAdapter(t *testing.T) { require.Equal(t, string(buf), fmt.Sprintf(`--- title: "test-command" --- + ## test-command -%s +%sbash test-command [flags] %s `, codeBlock, codeBlock))