You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
consolidate go list -m k8s.io/client-go calls for ENVTEST_VERSION, KUBE_VERSION, and KIND_NODE_VERSION
Avoid multiple redundant shell executions by extracting the client-go version once and deriving ENVTEST_VERSION, KUBE_VERSION (for PSA label), and KIND_NODE_VERSION from it. This improves efficiency and prevents unnecessary re-evaluations in Makefile.
go test -count=1 -v ./test/extension-developer-e2e/...
205
206
206
-
ENVTEST_VERSION := $(shell go list -m k8s.io/client-go | cut -d" " -f2 | sed 's/^v0\.\([[:digit:]]\{1,\}\)\.[[:digit:]]\{1,\}$$/1.\1.x/')
207
207
UNIT_TEST_DIRS := $(shell go list ./... | grep -v /test/)
208
208
COVERAGE_UNIT_DIR := $(ROOT_DIR)/coverage/unit
209
209
210
210
.PHONY: envtest-k8s-bins #HELP Uses setup-envtest to download and install the binaries required to run ENVTEST-test based locally at the project/bin directory.
211
211
envtest-k8s-bins: $(SETUP_ENVTEST)
212
212
mkdir -p $(ROOT_DIR)/bin
213
-
$(SETUP_ENVTEST) use -p env $(ENVTEST_VERSION)$(SETUP_ENVTEST_BIN_DIR_OVERRIDE)
213
+
$(SETUP_ENVTEST) use -p env $(KUBE_MINOR).x$(SETUP_ENVTEST_BIN_DIR_OVERRIDE)
214
214
215
215
.PHONY: test-unit
216
216
test-unit: $(SETUP_ENVTEST) envtest-k8s-bins #HELP Run the unit tests
0 commit comments