diff --git a/cmd/argoexec/commands/emissary_test.go b/cmd/argoexec/commands/emissary_test.go index 78cc0be041cc..3b5e199b77f2 100644 --- a/cmd/argoexec/commands/emissary_test.go +++ b/cmd/argoexec/commands/emissary_test.go @@ -49,7 +49,7 @@ func TestEmissary(t *testing.T) { }) t.Run("Sub-process", func(t *testing.T) { _ = os.Remove(varRunArgo + "/ctr/main/stdout") - err := run("(sleep 60; echo 'should not wait for sub-process')& echo -n hello") + err := run(`(sleep 60; echo 'should not wait for sub-process')& echo "hello\c"`) assert.NoError(t, err) data, err := os.ReadFile(varRunArgo + "/ctr/main/stdout") assert.NoError(t, err) diff --git a/workflow/executor/os-specific/command_test.go b/workflow/executor/os-specific/command_test.go index 53b07d5da96f..f247ac047f0f 100644 --- a/workflow/executor/os-specific/command_test.go +++ b/workflow/executor/os-specific/command_test.go @@ -11,7 +11,7 @@ import ( ) func TestSimpleStartCloser(t *testing.T) { - cmd := exec.Command("sh", "-c", "echo -n A123456789B123456789C123456789D123456789E123456789") + cmd := exec.Command("sh", "-c", `echo "A123456789B123456789C123456789D123456789E123456789\c"`) var stdoutWriter bytes.Buffer slowWriter := SlowWriter{ &stdoutWriter,