Skip to content

Commit

Permalink
Enable running tests with --endpoint flag. (#2729)
Browse files Browse the repository at this point in the history
* Enable running tests with --endpoint flag.

* Use the correct flag name.
  • Loading branch information
orsenthil authored Dec 27, 2023
1 parent a42364a commit a09272e
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions scripts/run-static-canary.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,13 @@ GINKGO_TEST_BUILD="$SCRIPT_DIR/../test/build"
# TEST_IMAGE_REGISTRY is the registry in test-infra-* accounts where e2e test images are stored
TEST_IMAGE_REGISTRY=${TEST_IMAGE_REGISTRY:-"617930562442.dkr.ecr.us-west-2.amazonaws.com"}

# If $ENDPOINT is set, as in it is for beta clusters, then add the --endpoint flag to the ginkgo test command
ENDPOINT_FLAG=""
if [ -n "$ENDPOINT" ]; then
ENDPOINT_FLAG="--eks-endpoint=$ENDPOINT"
fi


source "$SCRIPT_DIR"/lib/cluster.sh
source "$SCRIPT_DIR"/lib/canary.sh

Expand All @@ -24,11 +31,12 @@ function run_ginkgo_test() {
--aws-vpc-id="$VPC_ID" \
--ng-name-label-key="kubernetes.io/os" \
--ng-name-label-val="linux" \
--test-image-registry=$TEST_IMAGE_REGISTRY)
--test-image-registry=$TEST_IMAGE_REGISTRY \
"$ENDPOINT_FLAG")
}

load_cluster_details

run_ginkgo_test "STATIC_CANARY"

echo "all tests ran successfully in $(($SECONDS / 60)) minutes and $(($SECONDS % 60)) seconds"
echo "all tests ran successfully in $(($SECONDS / 60)) minutes and $(($SECONDS % 60)) seconds"

0 comments on commit a09272e

Please sign in to comment.