Skip to content

Commit

Permalink
Fix wait_until_object_does_not_exist() (knative#284)
Browse files Browse the repository at this point in the history
The function is currently checking the opposite, thus it times out most of the time.

Bonus: fix error message.
  • Loading branch information
adrcunha authored and knative-prow-robot committed Nov 30, 2018
1 parent 00db505 commit 0bf7d2a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/library.sh
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,8 @@ function wait_until_object_does_not_exist() {
fi
echo -n "Waiting until ${DESCRIPTION} does not exist"
for i in {1..150}; do # timeout after 5 minutes
if kubectl ${KUBECTL_ARGS} > /dev/null 2>&1; then
echo "\n${DESCRIPTION} does not exist"
if ! kubectl ${KUBECTL_ARGS} > /dev/null 2>&1; then
echo -e "\n${DESCRIPTION} does not exist"
return 0
fi
echo -n "."
Expand Down

0 comments on commit 0bf7d2a

Please sign in to comment.