diff options
| author | Paul Buetow <pbuetow@mimecast.com> | 2021-10-15 13:20:48 +0300 |
|---|---|---|
| committer | Paul Buetow <pbuetow@mimecast.com> | 2021-10-19 19:02:57 +0300 |
| commit | 10314cef906fd9b73e003be69c2f6b7b3d66570c (patch) | |
| tree | 03e8b96ad97d3382d439725166f83c774dc999a4 /integrationtests/commandutils.go | |
| parent | b27fc108ecd6eead5c97cf6e894bf8d639fff75c (diff) | |
Can configure DTail client not to mess with ~/.ssh/known_hosts via env var - this is useful for running unit and integration tests in jenkins
Diffstat (limited to 'integrationtests/commandutils.go')
| -rw-r--r-- | integrationtests/commandutils.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/integrationtests/commandutils.go b/integrationtests/commandutils.go index b448153..23b9c37 100644 --- a/integrationtests/commandutils.go +++ b/integrationtests/commandutils.go @@ -22,16 +22,17 @@ func runCommand(ctx context.Context, t *testing.T, stdoutFile, cmdStr string, return 0, fmt.Errorf("no such executable '%s', please compile first: %v", cmdStr, err) } + t.Log("Creating stdout file", stdoutFile) fd, err := os.Create(stdoutFile) if err != nil { return 0, nil } defer fd.Close() - t.Log(cmdStr, strings.Join(args, " ")) + t.Log("Running command", cmdStr, strings.Join(args, " ")) cmd := exec.CommandContext(ctx, cmdStr, args...) out, err := cmd.CombinedOutput() - + t.Log("Done running command!", err) fd.Write(out) return exitCodeFromError(err), err |
