From: Yu Watanabe Date: Thu, 23 May 2019 14:45:49 +0000 (+0900) Subject: test-network: drop redundant check_link_exists() X-Git-Tag: v243-rc1~369^2~4 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b08b056e190bf0f93bf723308c73b8cd0f3f3b78;p=thirdparty%2Fsystemd.git test-network: drop redundant check_link_exists() When wait_online() passes, then the link must exist. --- diff --git a/test/test-network/systemd-networkd-tests.py b/test/test-network/systemd-networkd-tests.py index 0dcd9cd496a..80c6b3a4fda 100755 --- a/test/test-network/systemd-networkd-tests.py +++ b/test/test-network/systemd-networkd-tests.py @@ -410,8 +410,6 @@ class NetworkdNetDevTests(unittest.TestCase, Utilities): self.start_networkd(0) self.wait_online(['bridge99', 'test1:degraded'], bool_any=True) - self.check_link_exists('bridge99') - self.check_link_exists('test1') self.check_operstate('bridge99', '(?:off|no-carrier)', setup_state='configuring') self.check_operstate('test1', 'degraded') @@ -842,9 +840,6 @@ class NetworkdNetDevTests(unittest.TestCase, Utilities): self.start_networkd(0) self.wait_online(['isataptun99:routable', 'dummy98:degraded']) - self.check_link_exists('dummy98') - self.check_link_exists('isataptun99') - output = subprocess.check_output(['ip', '-d', 'link', 'show', 'isataptun99'], universal_newlines=True).rstrip() print(output) self.assertRegex(output, "isatap ") @@ -1400,8 +1395,6 @@ class NetworkdNetWorkTests(unittest.TestCase, Utilities): self.start_networkd(0) self.wait_online(['dummy98:degraded']) - self.check_link_exists('dummy98') - self.assertEqual(self.read_ipv6_sysctl_attr('dummy98', 'forwarding'), '1') self.assertEqual(self.read_ipv6_sysctl_attr('dummy98', 'use_tempaddr'), '2') self.assertEqual(self.read_ipv6_sysctl_attr('dummy98', 'dad_transmits'), '3') @@ -1420,8 +1413,6 @@ class NetworkdNetWorkTests(unittest.TestCase, Utilities): self.start_networkd(0) self.wait_online(['dummy98:routable']) - self.check_link_exists('dummy98') - output = subprocess.check_output(['ip', '-4', 'address', 'show', 'dummy98'], universal_newlines=True).rstrip() print(output) self.assertRegex(output, 'inet 10.2.3.4/16 brd 10.2.255.255 scope global dummy98') @@ -1439,8 +1430,6 @@ class NetworkdNetWorkTests(unittest.TestCase, Utilities): self.start_networkd(0) self.wait_online(['dummy98:routable']) - self.check_link_exists('dummy98') - output = subprocess.check_output(['ip', '-4', 'address', 'show', 'dummy98'], universal_newlines=True).rstrip() print(output) self.assertRegex(output, 'inet 10.2.3.4/16 brd 10.2.255.255 scope global dummy98')