File tree 1 file changed +25
-2
lines changed
1 file changed +25
-2
lines changed Original file line number Diff line number Diff line change @@ -9,6 +9,8 @@ KUBECTL_VERSION= $(shell ./control-plane/build-support/scripts/read-yaml-config.
9
9
10
10
GO_MODULES := $(shell find . -name go.mod -exec dirname {} \; | sort)
11
11
12
+ GOTESTSUM_PATH? =$(shell command -v gotestsum)
13
+
12
14
# #@ Helm Targets
13
15
14
16
.PHONY : gen-helm-docs
@@ -97,11 +99,32 @@ control-plane-fips-dev-docker: ## Build consul-k8s-control-plane FIPS dev Docker
97
99
98
100
.PHONY : control-plane-test
99
101
control-plane-test : # # Run go test for the control plane.
100
- cd control-plane; go test ./...
102
+ ifeq ("$(GOTESTSUM_PATH ) ","")
103
+ cd control-plane && go test ./...
104
+ else
105
+ cd control-plane && \
106
+ gotestsum \
107
+ --format=short-verbose \
108
+ --debug \
109
+ --rerun-fails=3 \
110
+ --packages="./..."
111
+ endif
112
+
101
113
102
114
.PHONY : control-plane-ent-test
103
115
control-plane-ent-test : # # Run go test with Consul enterprise tests. The consul binary in your PATH must be Consul Enterprise.
104
- cd control-plane; go test ./... -tags=enterprise
116
+ ifeq ("$(GOTESTSUM_PATH ) ","")
117
+ cd control-plane && go test ./... -tags=enterprise
118
+ else
119
+ cd control-plane && \
120
+ gotestsum \
121
+ --format=short-verbose \
122
+ --debug \
123
+ --rerun-fails=3 \
124
+ --packages="./..." \
125
+ -- \
126
+ --tags enterprise
127
+ endif
105
128
106
129
.PHONY : control-plane-cov
107
130
control-plane-cov : # # Run go test with code coverage.
You can’t perform that action at this time.
0 commit comments