From ac8b70976bea6bfb11d166f389e0ade2357627d1 Mon Sep 17 00:00:00 2001 From: Paulo Truta Date: Sat, 12 Jun 2021 14:13:46 +0000 Subject: [PATCH] Added ExampleExecAndStream test --- internal/utils/utils_test.go | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/internal/utils/utils_test.go b/internal/utils/utils_test.go index 57dab2f..f053514 100644 --- a/internal/utils/utils_test.go +++ b/internal/utils/utils_test.go @@ -19,6 +19,17 @@ func TestExec(t *testing.T) { } } +func ExampleExecAndStream() { + ExecAndStream("/", "echo", []string{"Hello"}) + // Output: + // Hello + // + // out: + // Hello + // + // err: +} + func TestExecAndGetLines(t *testing.T) { testCommand := "echo" testArguments := []string{"$'Line1\nLine2\nLine3'"}