Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ fmt-verify:
vet: ## Run go vet against code.
go vet ./...

#If you are running in local and your helm dependency is outdated, you can run `make test MODE=local`
.PHONY: test
test: generate fmt vet envtest image-build verify-crds verify-helm-charts ## Run tests.
CGO_ENABLED=1 KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) --bin-dir $(LOCALBIN) -p path)" go test $$(go list ./... | grep -v /e2e | grep -v /conformance) -race -coverprofile cover.out
Expand Down Expand Up @@ -180,9 +181,10 @@ verify: vet fmt-verify generate ci-lint api-lint verify-all
verify-crds: kubectl-validate
hack/verify-manifests.sh

#If you are running in local and your helm dependency is outdated, you can run `make verify-helm-charts MODE=local`
.PHONY: verify-helm-charts
verify-helm-charts: helm-install
hack/verify-helm.sh
hack/verify-helm.sh $(MODE)

# Run static analysis.
.PHONY: verify-all
Expand Down
24 changes: 18 additions & 6 deletions hack/verify-helm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,18 @@
# limitations under the License.

SCRIPT_ROOT=$(dirname "${BASH_SOURCE}")/..
# Read the first argument, default to "ci" if not provided
MODE=${1:-ci}

if [ "$MODE" == "local" ]; then
# Local Mode: Permissive. Updates lock file automatically.
DEP_CMD="update"
echo "🔸 MODE: Local (Dev) - Using 'helm dependency update'"
else
# CI/CD Mode (Default): Strict. Fails if lock file is out of sync.
DEP_CMD="build"
echo "🔹 MODE: CI/CD (Strict) - Using 'helm dependency build'"
fi

declare -A test_cases_inference_pool

Expand All @@ -28,10 +40,10 @@ test_cases_inference_pool["latency-predictor"]="--set inferenceExtension.latency
# source (such as in the verify-all script)
make helm-install

echo "Building dependencies for inferencePool chart..."
${SCRIPT_ROOT}/bin/helm dependency build ${SCRIPT_ROOT}/config/charts/inferencepool
echo "Processing dependencies for inferencePool chart..."
${SCRIPT_ROOT}/bin/helm dependency ${DEP_CMD} ${SCRIPT_ROOT}/config/charts/inferencepool
if [ $? -ne 0 ]; then
echo "Helm dependency build failed."
echo "Helm dependency ${DEP_CMD} failed."
exit 1
fi

Expand All @@ -55,10 +67,10 @@ test_cases_epp_standalone["gke-provider"]="--set provider.name=gke --set inferen
test_cases_epp_standalone["latency-predictor"]="--set inferenceExtension.latencyPredictor.enabled=true --set inferenceExtension.endpointsServer.endpointSelector='app=llm-instance-gateway'"


echo "Building dependencies for epp-standalone chart..."
${SCRIPT_ROOT}/bin/helm dependency build ${SCRIPT_ROOT}/config/charts/epp-standalone
echo "Processing dependencies for epp-standalone chart..."
${SCRIPT_ROOT}/bin/helm dependency ${DEP_CMD} ${SCRIPT_ROOT}/config/charts/epp-standalone
if [ $? -ne 0 ]; then
echo "Helm dependency build failed."
echo "Helm dependency ${DEP_CMD} failed."
exit 1
fi

Expand Down