cosmetic: vertical alignment and consistency for better readability

This commit is contained in:
Matthias Radestock committed 2015-06-18 16:26:16 +01:00
1 parent 54b3061c50
commit d1e4a8ec8a
2 files changed
+26 -26

No files matched your search

+4 -4
View File
@@ -13,12 +13,12 @@ start_suite "Ping over cross-host weave network (with and without IPAM)"
weave_on $HOST1 launch -iprange $UNIVERSE -ipsubnet $SUBNET_1
weave_on $HOST2 launch -iprange $UNIVERSE -ipsubnet $SUBNET_1 $HOST1
start_container $HOST1 $C1/24 --name=c1
start_container $HOST2 ip:$C2/24 --name=c2
start_container $HOST1 $C1/24 --name=c1
start_container $HOST2 ip:$C2/24 --name=c2
assert_raises "exec_on $HOST1 c1 $PING $C2"
start_container $HOST1 --name=c3
start_container $HOST2 net:default --name=c4
start_container $HOST1 --name=c3
start_container $HOST2 net:default --name=c4
C4=$(container_ip $HOST2 c4)
assert_raises "exec_on $HOST1 c3 $PING $C4"
+22 -22
View File
@@ -50,37 +50,37 @@ weave_on $HOST1 launch -debug -iprange 10.2.3.0/24
launch_dns_on $HOST1 10.254.254.254/24
# Run container with three cidrs
CID=$(start_container $HOST1 ip:10.2.1.1/24 10.2.2.1/24 net:10.2.3.0/24 --name=multicidr -h $NAME | cut -b 1-12)
assert_container_cidrs $HOST1 $CID 10.2.1.1/24 10.2.2.1/24 10.2.3.1/24
assert_zone_records $HOST1 $CID $NAME. 10.2.1.1 10.2.2.1 10.2.3.1
CID=$(start_container $HOST1 10.2.1.1/24 ip:10.2.2.1/24 net:10.2.3.0/24 --name=multicidr -h $NAME | cut -b 1-12)
assert_container_cidrs $HOST1 $CID 10.2.1.1/24 10.2.2.1/24 10.2.3.1/24
assert_zone_records $HOST1 $CID $NAME. 10.2.1.1 10.2.2.1 10.2.3.1
# Remove two of them
weave_on $HOST1 detach 10.2.1.1/24 net:10.2.3.0/24 $CID
assert_container_cidrs $HOST1 $CID 10.2.2.1/24
assert_zone_records $HOST1 $CID $NAME. 10.2.2.1
weave_on $HOST1 detach ip:10.2.2.1/24 net:10.2.3.0/24 $CID
assert_container_cidrs $HOST1 $CID 10.2.1.1/24
assert_zone_records $HOST1 $CID $NAME. 10.2.1.1
# Put them both back
weave_on $HOST1 attach ip:10.2.1.1/24 net:10.2.3.0/24 $CID
assert_container_cidrs $HOST1 $CID 10.2.2.1/24 10.2.1.1/24 10.2.3.1/24
assert_zone_records $HOST1 $CID $NAME. 10.2.2.1 10.2.1.1 10.2.3.1
weave_on $HOST1 attach ip:10.2.2.1/24 net:10.2.3.0/24 $CID
assert_container_cidrs $HOST1 $CID 10.2.1.1/24 10.2.2.1/24 10.2.3.1/24
assert_zone_records $HOST1 $CID $NAME. 10.2.1.1 10.2.2.1 10.2.3.1
# Stop the container, restart with three IPs
docker_on $HOST1 stop $CID
weave_on $HOST1 start 10.2.1.1/24 ip:10.2.2.1/24 net:10.2.3.0/24 $CID
assert_container_cidrs $HOST1 $CID 10.2.1.1/24 10.2.2.1/24 10.2.3.1/24
assert_zone_records $HOST1 $CID $NAME. 10.2.1.1 10.2.2.1 10.2.3.1
docker_on $HOST1 stop $CID
weave_on $HOST1 start 10.2.1.1/24 ip:10.2.2.1/24 net:10.2.3.0/24 $CID
assert_container_cidrs $HOST1 $CID 10.2.1.1/24 10.2.2.1/24 10.2.3.1/24
assert_zone_records $HOST1 $CID $NAME. 10.2.1.1 10.2.2.1 10.2.3.1
# Expose some cidrs
weave_on $HOST1 expose 10.2.1.2/24 10.2.2.2/24 net:10.2.3.0/24
assert_bridge_cidrs $HOST1 weave 10.2.1.2/24 10.2.2.2/24 10.2.3.2/24
# Expose three cidrs
weave_on $HOST1 expose 10.2.1.2/24 ip:10.2.2.2/24 net:10.2.3.0/24
assert_bridge_cidrs $HOST1 weave 10.2.1.2/24 10.2.2.2/24 10.2.3.2/24
# Hide some cidrs
weave_on $HOST1 hide 10.2.1.2/24 net:10.2.3.0/24
assert_bridge_cidrs $HOST1 weave 10.2.2.2/24
# Hide two of them
weave_on $HOST1 hide ip:10.2.2.2/24 net:10.2.3.0/24
assert_bridge_cidrs $HOST1 weave 10.2.1.2/24
# Now detach and run another container to check we have released IPs in IPAM
weave_on $HOST1 detach $CID
CID2=$(start_container $HOST1 net:10.2.3.0/24)
assert_container_cidrs $HOST1 $CID2 10.2.3.1/24
weave_on $HOST1 detach $CID
CID2=$(start_container $HOST1 net:10.2.3.0/24)
assert_container_cidrs $HOST1 $CID2 10.2.3.1/24
end_suite