replace sleep with retry

Signed-off-by: Victor Vieux <vieux@docker.com>
This commit is contained in:
Victor Vieux 2016-02-10 00:27:05 -08:00
parent cf2d7b12b1
commit 5974a4a509
1 changed files with 1 additions and 2 deletions

View File

@ -188,8 +188,7 @@ function teardown() {
# Restart node-0 # Restart node-0
docker_host start ${DOCKER_CONTAINERS[0]} docker_host start ${DOCKER_CONTAINERS[0]}
sleep 6 retry 5 1 eval "test \"$(docker_swarm info | grep -c \"Status: Unhealthy\" | wc -l)\" = '0'"
[[ $(docker_swarm info | grep -c "Status: Unhealthy") -eq 0 ]]
# Stop node-1 # Stop node-1
docker_host stop ${DOCKER_CONTAINERS[1]} docker_host stop ${DOCKER_CONTAINERS[1]}