From bd71815fc600aacdcf5ae5a6b03d53ca1c28f551 Mon Sep 17 00:00:00 2001 From: Christian Winther Date: Thu, 15 Feb 2024 22:28:36 +0100 Subject: [PATCH] sync tests --- cmd/disable/disable.go | 2 +- cmd/disable/tests/disable-a-key/stdout.golden | 2 +- cmd/disable/tests/{disable-a-key.env => disable-key-b.env} | 0 cmd/disable/tests/{disable-a-key.run => disable-key-b.run} | 0 cmd/disable/tests/disable-key-b/env.golden | 6 ++++++ cmd/disable/tests/disable-key-b/stderr.golden | 1 + cmd/disable/tests/disable-key-b/stdout.golden | 2 ++ 7 files changed, 11 insertions(+), 2 deletions(-) rename cmd/disable/tests/{disable-a-key.env => disable-key-b.env} (100%) rename cmd/disable/tests/{disable-a-key.run => disable-key-b.run} (100%) create mode 100644 cmd/disable/tests/disable-key-b/env.golden create mode 100644 cmd/disable/tests/disable-key-b/stderr.golden create mode 100644 cmd/disable/tests/disable-key-b/stdout.golden diff --git a/cmd/disable/disable.go b/cmd/disable/disable.go index 923f6f3..7c395e0 100644 --- a/cmd/disable/disable.go +++ b/cmd/disable/disable.go @@ -46,7 +46,7 @@ func NewCommand() *cobra.Command { tui.StdoutFromContext(cmd.Context()). Success(). - Printfln("Key [%s] was successfully disabled", key) + Printfln("Key [ %s ] was successfully disabled", key) return nil }, diff --git a/cmd/disable/tests/disable-a-key/stdout.golden b/cmd/disable/tests/disable-a-key/stdout.golden index e258b95..69e127d 100644 --- a/cmd/disable/tests/disable-a-key/stdout.golden +++ b/cmd/disable/tests/disable-a-key/stdout.golden @@ -1,2 +1,2 @@ ---- exec command line 0: [disable KEY_B] -Key [KEY_B] was successfully disabled +Key [ KEY_B ] was successfully disabled diff --git a/cmd/disable/tests/disable-a-key.env b/cmd/disable/tests/disable-key-b.env similarity index 100% rename from cmd/disable/tests/disable-a-key.env rename to cmd/disable/tests/disable-key-b.env diff --git a/cmd/disable/tests/disable-a-key.run b/cmd/disable/tests/disable-key-b.run similarity index 100% rename from cmd/disable/tests/disable-a-key.run rename to cmd/disable/tests/disable-key-b.run diff --git a/cmd/disable/tests/disable-key-b/env.golden b/cmd/disable/tests/disable-key-b/env.golden new file mode 100644 index 0000000..1c0767f --- /dev/null +++ b/cmd/disable/tests/disable-key-b/env.golden @@ -0,0 +1,6 @@ +KEY_A="I'm key A" + +# Comment for KEY_B +#KEY_B="I'm key B" + +KEY_C="I'm key C" diff --git a/cmd/disable/tests/disable-key-b/stderr.golden b/cmd/disable/tests/disable-key-b/stderr.golden new file mode 100644 index 0000000..b9de686 --- /dev/null +++ b/cmd/disable/tests/disable-key-b/stderr.golden @@ -0,0 +1 @@ +---- exec command line 0: [disable KEY_B] diff --git a/cmd/disable/tests/disable-key-b/stdout.golden b/cmd/disable/tests/disable-key-b/stdout.golden new file mode 100644 index 0000000..69e127d --- /dev/null +++ b/cmd/disable/tests/disable-key-b/stdout.golden @@ -0,0 +1,2 @@ +---- exec command line 0: [disable KEY_B] +Key [ KEY_B ] was successfully disabled