Skip to content

Commit

Permalink
ensure stderr can be used in err checks
Browse files Browse the repository at this point in the history
Signed-off-by: Kristoffer Dalby <[email protected]>
  • Loading branch information
kradalby committed Aug 30, 2024
1 parent 4bd6936 commit cb12055
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion integration/dockertestutil/execute.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ func ExecuteCommand(
exitCode, err := resource.Exec(
cmd,
dockertest.ExecOptions{
Env: append(env, "HEADSCALE_LOG_LEVEL=disabled"),
Env: append(env, "HEADSCALE_LOG_LEVEL=info"),
StdOut: &stdout,
StdErr: &stderr,
},
Expand Down
2 changes: 1 addition & 1 deletion integration/hsic/hsic.go
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,7 @@ func (t *HeadscaleInContainer) Execute(
log.Printf("command stdout: %s\n", stdout)
}

return "", err
return stdout, fmt.Errorf("executing command in docker: %w, stderr: %s", err, stderr)
}

return stdout, nil
Expand Down

0 comments on commit cb12055

Please sign in to comment.