From: Yu Watanabe Date: Tue, 16 Jul 2019 16:01:07 +0000 (+0900) Subject: test-network: extend sleep time X-Git-Tag: v243-rc1~107^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F13069%2Fhead;p=thirdparty%2Fsystemd.git test-network: extend sleep time Even if addresses provided by DHCP is assigned, the state file may not be written yet, or resolved may not receive the state change signal yet, or resolved may not process the signal yet... --- diff --git a/test/test-network/systemd-networkd-tests.py b/test/test-network/systemd-networkd-tests.py index 1eda8ee8e84..2fbd9ae7b76 100755 --- a/test/test-network/systemd-networkd-tests.py +++ b/test/test-network/systemd-networkd-tests.py @@ -2815,7 +2815,7 @@ class NetworkdDHCPClientTests(unittest.TestCase, Utilities): self.wait_address('veth99', r'inet 192.168.5.[0-9]*/24 brd 192.168.5.255 scope global dynamic', ipv='-4') self.wait_address('veth99', r'inet6 2600::[0-9a-f]*/128 scope global (?:dynamic noprefixroute|noprefixroute dynamic)', ipv='-6') - time.sleep(3) + time.sleep(10) output = check_output(*resolvectl_cmd, 'dns', 'veth99', env=env) print(output) self.assertRegex(output, '192.168.5.1') @@ -2833,7 +2833,7 @@ class NetworkdDHCPClientTests(unittest.TestCase, Utilities): self.wait_address('veth99', r'inet 192.168.5.[0-9]*/24 brd 192.168.5.255 scope global dynamic', ipv='-4') self.wait_address('veth99', r'inet6 2600::[0-9a-f]*/128 scope global (?:dynamic noprefixroute|noprefixroute dynamic)', ipv='-6') - time.sleep(3) + time.sleep(10) output = check_output(*resolvectl_cmd, 'dns', 'veth99', env=env) print(output) self.assertNotRegex(output, '192.168.5.1') @@ -2851,7 +2851,7 @@ class NetworkdDHCPClientTests(unittest.TestCase, Utilities): self.wait_address('veth99', r'inet 192.168.5.[0-9]*/24 brd 192.168.5.255 scope global dynamic', ipv='-4') self.wait_address('veth99', r'inet6 2600::[0-9a-f]*/128 scope global (?:dynamic noprefixroute|noprefixroute dynamic)', ipv='-6') - time.sleep(3) + time.sleep(10) output = check_output(*resolvectl_cmd, 'dns', 'veth99', env=env) print(output) self.assertRegex(output, '192.168.5.1') @@ -2869,7 +2869,7 @@ class NetworkdDHCPClientTests(unittest.TestCase, Utilities): self.wait_address('veth99', r'inet 192.168.5.[0-9]*/24 brd 192.168.5.255 scope global dynamic', ipv='-4') self.wait_address('veth99', r'inet6 2600::[0-9a-f]*/128 scope global (?:dynamic noprefixroute|noprefixroute dynamic)', ipv='-6') - time.sleep(3) + time.sleep(10) output = check_output(*resolvectl_cmd, 'dns', 'veth99', env=env) print(output) self.assertRegex(output, '192.168.5.1')