From f6872299e7b5db04b20e23948a13a4670a8a5139 Mon Sep 17 00:00:00 2001 From: kfox1111 Date: Thu, 22 Aug 2024 09:40:41 -0700 Subject: [PATCH] Fix delayed ingress startup in tests (#438) * Fix delayed ingress startup in tests Signed-off-by: Kevin Fox * Fix lint Signed-off-by: Kevin Fox --------- Signed-off-by: Kevin Fox --- .github/tests/common.sh | 10 ++++++++++ examples/nested-full/run-tests.sh | 2 +- examples/nested-security/run-tests.sh | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.github/tests/common.sh b/.github/tests/common.sh index 0566665..d833cf6 100755 --- a/.github/tests/common.sh +++ b/.github/tests/common.sh @@ -72,6 +72,16 @@ $(helm ls -A | sed 's/\t/ | /g' | sed 's/^/| /' | sed 's/$/ |/' | sed '/^| NAME. EOF } +common_test_url () ( +count=10 +while true; do + if curl "$1"; then exit 0; fi + sleep 2 + count=$((count-1)) + [ $count -le 0 ] && exit 1 +done +) + # Used just for testing. You should provide your own values as described in the install instructions. common_test_your_values () { cat > /tmp/$$.example-your-values.yaml <