From 0a4c31f707bf1b17aadaaa13cf0bc18dd6c007b5 Mon Sep 17 00:00:00 2001 From: Diego Lovison Date: Wed, 13 Nov 2024 13:33:27 -0300 Subject: [PATCH] Print if REGISTRY_ADDRESS is not defined --- .github/scripts/tests/collect_logs.sh | 2 +- .github/scripts/tests/tests.sh | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/scripts/tests/collect_logs.sh b/.github/scripts/tests/collect_logs.sh index 29cd7c155..e58634d0f 100755 --- a/.github/scripts/tests/collect_logs.sh +++ b/.github/scripts/tests/collect_logs.sh @@ -30,7 +30,7 @@ function display_pod_info { local NAMESPACE=$1 local POD_NAMES - POD_NAMES=$(kubectl -n "${DSPA_NS}" get pods -o custom-columns=":metadata.name") + POD_NAMES=$(kubectl -n "${DSPA_NS}" get pods -o custom-columns=":metadata.name" --field-selector=status.phase=Failed) if [[ -z "${POD_NAMES}" ]]; then echo "No pods found in namespace '${NAMESPACE}'." diff --git a/.github/scripts/tests/tests.sh b/.github/scripts/tests/tests.sh index ae54c80ff..07c27455c 100755 --- a/.github/scripts/tests/tests.sh +++ b/.github/scripts/tests/tests.sh @@ -31,7 +31,10 @@ ENDPOINT_TYPE="service" get_dspo_image() { if [ "$REGISTRY_ADDRESS" = "" ]; then - echo "REGISTRY_ADDRESS variable not defined." && exit 1 + # this function is called by `IMG=$(get_dspo_image)` that captures the standard output of get_dspo_image + set -x + echo "REGISTRY_ADDRESS variable not defined." + exit 1 fi local image="${REGISTRY_ADDRESS}/data-science-pipelines-operator" echo $image