From d5914c8de36e6826444b4f7a8b7c2a71b2288e9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Leandro=20L=C3=B3pez=20=28inkel=29?= Date: Wed, 21 Jun 2023 18:32:42 -0300 Subject: [PATCH] Add regression test for multienv output with comma in values MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See #2765 for an issue report. Signed-off-by: Leandro López (inkel) --- server/core/runtime/multienv_step_runner_test.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/server/core/runtime/multienv_step_runner_test.go b/server/core/runtime/multienv_step_runner_test.go index 171f026117..f7d6b1132f 100644 --- a/server/core/runtime/multienv_step_runner_test.go +++ b/server/core/runtime/multienv_step_runner_test.go @@ -37,6 +37,11 @@ func TestMultiEnvStepRunner_Run(t *testing.T) { ExpErr: "Invalid environment variable definition: TF_VAR_REPODEFINEDVARIABLE_NO_VALUE", Version: "v1.2.3", }, + { + Command: `echo 'TF_VAR1_MULTILINE="foo\\nbar",TF_VAR2_VALUEWITHCOMMA="one,two",TF_VAR3_CONTROL=true'`, + ExpOut: "Dynamic environment variables added:\nTF_VAR1_MULTILINE\nTF_VAR2_VALUEWITHCOMMA\nTF_VAR3_CONTROL\n", + Version: "v1.2.3", + }, } RegisterMockTestingT(t) tfClient := mocks.NewMockClient()