@@ -95,9 +95,9 @@ TEST_ASSET_DIR ?= $(ROOTDIR)/_test
95
95
# Directory to store downloaded conformance tests for different versions
96
96
CONFORMANCE_DIR ?= $(TEST_ASSET_DIR ) /conformance
97
97
# Gateway API version used for conformance testing
98
- GATEWAY_API_VERSION ?= v1.2.0
98
+ CONFORMANCE_VERSION ?= v1.2.0
99
99
# Fetch the module directory for the specified version of the Gateway API
100
- GATEWAY_API_MODULE_DIR := $(shell go list -m -json sigs.k8s.io/gateway-api@$(GATEWAY_API_VERSION ) | jq -r '.Dir')
100
+ GATEWAY_API_MODULE_DIR := $(shell go mod download -json sigs.k8s.io/gateway-api@$(CONFORMANCE_VERSION ) | jq -r '.Dir')
101
101
102
102
# This is the location where assets are placed after a test failure
103
103
# This is used by our e2e tests to emit information about the running instance of Gloo Gateway
@@ -1244,14 +1244,14 @@ build-test-chart: ## Build the Helm chart and place it in the _test directory
1244
1244
# ----------------------------------------------------------------------------------
1245
1245
1246
1246
# Download and prepare the conformance test suite for a specific Gateway API version
1247
- $(CONFORMANCE_DIR ) /$(GATEWAY_API_VERSION ) /conformance_test.go :
1248
- mkdir -p $(CONFORMANCE_DIR ) /$(GATEWAY_API_VERSION )
1249
- go mod download sigs.k8s.io/gateway-api@$(GATEWAY_API_VERSION )
1247
+ $(CONFORMANCE_DIR ) /$(CONFORMANCE_VERSION ) /conformance_test.go :
1248
+ mkdir -p $(CONFORMANCE_DIR ) /$(CONFORMANCE_VERSION )
1249
+ go mod download sigs.k8s.io/gateway-api@$(CONFORMANCE_VERSION )
1250
1250
cp $(GATEWAY_API_MODULE_DIR ) /conformance/conformance_test.go $@
1251
1251
1252
1252
# Install the correct version of Gateway API CRDs in the Kubernetes cluster
1253
1253
install-crds :
1254
- kubectl apply -f https://github.com/kubernetes-sigs/gateway-api/releases/download/$(GATEWAY_API_VERSION ) /experimental-install.yaml
1254
+ kubectl apply -f https://github.com/kubernetes-sigs/gateway-api/releases/download/$(CONFORMANCE_VERSION ) /experimental-install.yaml
1255
1255
1256
1256
# Update go.mod to replace Gateway API module with the version used for conformance testing
1257
1257
update-mod :
@@ -1265,18 +1265,18 @@ reset-mod:
1265
1265
# Common arguments for conformance testing
1266
1266
CONFORMANCE_SUPPORTED_FEATURES ?= -supported-features=Gateway,ReferenceGrant,HTTPRoute,HTTPRouteQueryParamMatching,HTTPRouteMethodMatching,HTTPRouteResponseHeaderModification,HTTPRoutePortRedirect,HTTPRouteHostRewrite,HTTPRouteSchemeRedirect,HTTPRoutePathRedirect,HTTPRouteHostRewrite,HTTPRoutePathRewrite,HTTPRouteRequestMirror
1267
1267
CONFORMANCE_SUPPORTED_PROFILES ?= -conformance-profiles=GATEWAY-HTTP
1268
- CONFORMANCE_REPORT_ARGS ?= -report-output=$(CONFORMANCE_DIR ) /$(GATEWAY_API_VERSION ) /$(VERSION ) -report.yaml -organization=solo.io -project=gloo-gateway -version=$(VERSION ) -url=github.com/solo-io/gloo -contact=github.com/solo-io/gloo/issues/new/choose
1268
+ CONFORMANCE_REPORT_ARGS ?= -report-output=$(CONFORMANCE_DIR ) /$(CONFORMANCE_VERSION ) /$(VERSION ) -report.yaml -organization=solo.io -project=gloo-gateway -version=$(VERSION ) -url=github.com/solo-io/gloo -contact=github.com/solo-io/gloo/issues/new/choose
1269
1269
CONFORMANCE_ARGS := -gateway-class=gloo-gateway $(CONFORMANCE_SUPPORTED_FEATURES ) $(CONFORMANCE_SUPPORTED_PROFILES ) $(CONFORMANCE_REPORT_ARGS )
1270
1270
1271
1271
# Run conformance tests for the specified Gateway API version
1272
1272
.PHONY : conformance
1273
- conformance : $(CONFORMANCE_DIR ) /$(GATEWAY_API_VERSION ) /conformance_test.go install-crds update-mod
1273
+ conformance : $(CONFORMANCE_DIR ) /$(CONFORMANCE_VERSION ) /conformance_test.go install-crds update-mod
1274
1274
@trap " make reset-mod" EXIT; \
1275
- go test -mod=mod -ldflags=$(LDFLAGS ) -tags conformance -test.v $(CONFORMANCE_DIR ) /$(GATEWAY_API_VERSION ) /... -args $(CONFORMANCE_ARGS )
1275
+ go test -mod=mod -ldflags=$(LDFLAGS ) -tags conformance -test.v $(CONFORMANCE_DIR ) /$(CONFORMANCE_VERSION ) /... -args $(CONFORMANCE_ARGS )
1276
1276
1277
1277
.PHONY : conformance-% # # Run the conformance test suite
1278
- conformance-% : $(CONFORMANCE_DIR ) /$(GATEWAY_API_VERSION ) /conformance_test.go
1279
- go test -mod=mod -ldflags=$(LDFLAGS ) -tags conformance -test.v $(CONFORMANCE_DIR ) /$(GATEWAY_API_VERSION ) /... -args $(CONFORMANCE_ARGS ) \
1278
+ conformance-% : $(CONFORMANCE_DIR ) /$(CONFORMANCE_VERSION ) /conformance_test.go
1279
+ go test -mod=mod -ldflags=$(LDFLAGS ) -tags conformance -test.v $(CONFORMANCE_DIR ) /$(CONFORMANCE_VERSION ) /... -args $(CONFORMANCE_ARGS ) \
1280
1280
-run-test=$*
1281
1281
1282
1282
# ----------------------------------------------------------------------------------
0 commit comments