debian/tests/networkd: For IPv6 tests, also wait for IPv4 address to arrive

s-n-wait-online already exits after getting an IPv6 address, but we verify
both.
This commit is contained in:
Martin Pitt 2015-11-27 11:12:40 +01:00
parent 34165f8d34
commit 2bfa2091e2
2 changed files with 6 additions and 2 deletions

3
debian/changelog vendored
View File

@ -17,6 +17,9 @@ systemd (228-3) UNRELEASED; urgency=medium
* debian/tests/networkd: If /etc/resolv.conf already has three nameservers,
accept that too (as then the additional test one can't be added any more).
* Fix FTBFS on x32. Thanks Helmut Grohne! (Closes: #805910)
* debian/tests/networkd: For IPv6 tests, also wait for IPv4 address to
arrive; s-n-wait-online already exits after getting an IPv6 address, but
we verify both.
[ Michael Biebl ]
* Bump Build-Depends on libdw-dev to (>= 0.158) as per configure.ac.

View File

@ -121,11 +121,12 @@ DHCP=%s
if ipv6:
# check iface state and IP 6 address; FIXME: we need to wait a bit
# longer, as the iface is "configured" already with IPv4
# longer, as the iface is "configured" already with IPv4 *or*
# IPv6, but we want to wait for both
timeout = 10
while timeout > 0:
out = subprocess.check_output(['ip', 'a', 'show', 'dev', self.iface])
if b'state UP' in out and b'inet6 2600' in out:
if b'state UP' in out and b'inet6 2600' in out and b'inet 192.168' in out:
break
time.sleep(1)
timeout -= 1