Peer list persistence smoke test
This commit is contained in:
1 parent
4b758dd130
commit
f9dd763774
3 files changed
+55
-18
No files matched your search
@@ -249,6 +249,25 @@ assert_dns_ptr_record() {
|
||||
assert "exec_on $1 $2 getent hosts $4 | tr -s ' '" "$4 $3"
|
||||
}
|
||||
|
||||
# Kill a container process and make sure it's restarted by Docker
|
||||
check_restart() {
|
||||
OLD_PID=$(container_pid $1 $2)
|
||||
|
||||
run_on $1 sudo kill $OLD_PID
|
||||
|
||||
for i in $(seq 1 10); do
|
||||
NEW_PID=$(container_pid $1 $2)
|
||||
|
||||
if [ $NEW_PID != 0 -a $NEW_PID != $OLD_PID ] ; then
|
||||
return 0
|
||||
fi
|
||||
|
||||
sleep 1
|
||||
done
|
||||
|
||||
return 1
|
||||
}
|
||||
|
||||
start_suite() {
|
||||
for host in $HOSTS; do
|
||||
[ -z "$DEBUG" ] || echo "Cleaning up on $host: removing all containers and resetting weave"
|
||||
|
||||
Reference in new issue
Block a user