From 6af14152c1599e8a461043c2ea6fba8a78fd4ebe Mon Sep 17 00:00:00 2001 From: YujiOshima Date: Mon, 16 Apr 2018 23:37:18 +0000 Subject: [PATCH] improve test script Signed-off-by: YujiOshima --- test/scripts/run-tests.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/scripts/run-tests.sh b/test/scripts/run-tests.sh index de2e171eb79..8fc4a089b69 100755 --- a/test/scripts/run-tests.sh +++ b/test/scripts/run-tests.sh @@ -54,11 +54,13 @@ cd ${GO_DIR} ./deploy.sh TIMEOUT=60 -until kubectl get pods -n katib | grep 1/1 | [[ $(wc -l) -eq 7 ]]; do +PODNUM=$(kubectl get pods -n katib | grep -v NAME | wc -l) +until kubectl get pods -n katib | grep 1/1 | [[ $(wc -l) -eq $PODNUM ]]; do sleep 10 TIMEOUT=$(( TIMEOUT - 1 )) if [[ $TIMEOUT -eq 0 ]];then echo "NG" + kubectl get pods -n katib exit 1 fi done