New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Install gotestsum if needed for junit results #98668
Conversation
/sig testing |
/retest |
return | ||
kube::log::status "gotestsum not found; installing from hack/tools" | ||
pushd "${KUBE_ROOT}/hack/tools" >/dev/null | ||
GO111MODULE=on go install gotest.tools/gotestsum |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see us setting up a GOBIN / adding it to path anywhere (am I forgetting this happening in one of the sourced files?)
We want to avoid clobbering the system installed copy and usually have a GOBIN under _output like:
kubernetes/hack/verify-govet-levee.sh
Lines 30 to 31 in 792b4b1
export GOBIN="${KUBE_OUTPUT_BINPATH}" | |
PATH="${GOBIN}:${PATH}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We want to avoid clobbering the system installed copy
this only runs if we can't find gotestsum
in the path already
kube::golang::setup_env (called at the top of this file) sets GOPATH and clears GOBIN, so go install goes under _output/local/go/bin
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can probably dedupe this in other files then, but not in this PR 🙃
/lgtm |
/sig testing |
/triage accepted |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: BenTheElder, liggitt The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
Installs gotestsum if needed by
make test
Does this PR introduce a user-facing change?:
/cc @BenTheElder