Skip to content

Commit

Permalink
(copy of PR #3310)
Browse files Browse the repository at this point in the history
  • Loading branch information
zmerlynn committed Aug 25, 2023
1 parent eb17026 commit 551c4a3
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
16 changes: 16 additions & 0 deletions build/includes/sdk.mk
Original file line number Diff line number Diff line change
Expand Up @@ -216,3 +216,19 @@ sdk-shell-csharp:
sdk-publish-csharp: RELEASE_VERSION ?= $(base_version)
sdk-publish-csharp:
$(MAKE) run-sdk-command-csharp COMMAND=publish VERSION=$(RELEASE_VERSION) DOCKER_RUN_ARGS="$(DOCKER_RUN_ARGS) -it"

# difference in sdks before and after gen-all-sdk-grpc target
test-gen-all-sdk-grpc:
make gen-all-sdk-grpc
diff_output=$$(git diff --name-status HEAD -- ../sdks); \
diff_output_test_sdk=$$(git diff --name-status HEAD -- ../test/sdk); \
if [ -z "$$diff_output" ] && [ -z "$$diff_output_test_sdk" ]; then \
echo "No differences found."; \
git clean -xdf ../sdks ../test/sdk; \
rm -rf .gocache; \
else \
echo "FAILURE: Differences found."; \
echo "$$diff_output"; \
echo "$$diff_output_test_sdk"; \
exit 1; \
fi
11 changes: 11 additions & 0 deletions cloudbuild.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,16 @@ steps:
dir: "build"
args: ["ensure-build-sdk-image-base"]

#
# Preventing SDKs failure in CI
#
- name: "make-docker"
id: test-gen-all-sdk-grpc
waitFor:
- ensure-build-sdk-image-base
dir: "build"
args: ["test-gen-all-sdk-grpc"]

#
# Preventing Broken PR Merges in CI
#
Expand All @@ -134,6 +144,7 @@ steps:
waitFor:
- pull-build-image
- test-gen-crd-client
- test-gen-all-sdk-grpc
dir: "build"
args: ["lint"] # pull the build image if it exists

Expand Down

0 comments on commit 551c4a3

Please sign in to comment.