Skip to content

Commit

Permalink
Bump uptest version to v0.13.1 and use crddiff tool
Browse files Browse the repository at this point in the history
Signed-off-by: Fatih Türken <[email protected]>
  • Loading branch information
turkenf committed Oct 31, 2024
1 parent 8b3874d commit b243c4d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,13 @@ GO_SUBDIRS += cmd internal apis
KIND_VERSION = v0.21.0
UP_VERSION = v0.28.0
UP_CHANNEL = stable
UPTEST_VERSION = v0.11.1
UPTEST_VERSION = v0.13.1
UPTEST_LOCAL_VERSION = v0.13.0
UPTEST_LOCAL_CHANNEL = stable
KUSTOMIZE_VERSION = v5.3.0
YQ_VERSION = v4.40.5
CROSSPLANE_VERSION = 1.14.6
CRDDIFF_VERSION = v0.12.1

-include build/makelib/k8s_tools.mk

Expand Down Expand Up @@ -216,15 +217,15 @@ e2e: local-deploy uptest

# TODO: please move this to the common build submodule
# once the use cases mature
crddiff: $(UPTEST)
crddiff:
@$(INFO) Checking breaking CRD schema changes
@for crd in $${MODIFIED_CRD_LIST}; do \
if ! git cat-file -e "$${GITHUB_BASE_REF}:$${crd}" 2>/dev/null; then \
echo "CRD $${crd} does not exist in the $${GITHUB_BASE_REF} branch. Skipping..." ; \
continue ; \
fi ; \
echo "Checking $${crd} for breaking API changes..." ; \
changes_detected=$$($(UPTEST) crddiff revision --enable-upjet-extensions <(git cat-file -p "$${GITHUB_BASE_REF}:$${crd}") "$${crd}" 2>&1) ; \
changes_detected=$$(go run github.com/upbound/uptest/cmd/crddiff@$(CRDDIFF_VERSION) revision --enable-upjet-extensions <(git cat-file -p "$${GITHUB_BASE_REF}:$${crd}") "$${crd}" 2>&1) ; \
if [[ $$? != 0 ]] ; then \
printf "\033[31m"; echo "Breaking change detected!"; printf "\033[0m" ; \
echo "$${changes_detected}" ; \
Expand Down

0 comments on commit b243c4d

Please sign in to comment.