diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2020-07-09 07:01:45 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-09 07:01:45 +0200 |
commit | 5157d719f02978ed3a034bb2f0cdb16ca90140da (patch) | |
tree | 6ecfe45af818218fba36322d04238ae1700db684 | |
parent | NEWS: add blurb about os-release and $container_host_* (diff) | |
parent | test-netowrk: in test_bridge_configure_without_carrier, avoid strange test fa... (diff) | |
download | systemd-5157d719f02978ed3a034bb2f0cdb16ca90140da.tar.xz systemd-5157d719f02978ed3a034bb2f0cdb16ca90140da.zip |
Merge pull request #16411 from ddstreet/bridge_without_carrier_fails
Bridge without carrier fails
-rwxr-xr-x | test/test-network/systemd-networkd-tests.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/test/test-network/systemd-networkd-tests.py b/test/test-network/systemd-networkd-tests.py index caf077c836..4dca56f7dc 100755 --- a/test/test-network/systemd-networkd-tests.py +++ b/test/test-network/systemd-networkd-tests.py @@ -2879,8 +2879,7 @@ class NetworkdBridgeTests(unittest.TestCase, Utilities): with self.subTest(test=test): if test == 'no-slave': # bridge has no slaves; it's up but *might* not have carrier - # It may take very long time that the interface become configured state. - self.wait_online(['bridge99:no-carrier'], timeout='2m', setup_state=None) + self.wait_operstate('bridge99', operstate=r'(no-carrier|routable)', setup_state=None, setup_timeout=30) # due to a bug in the kernel, newly-created bridges are brought up # *with* carrier, unless they have had any setting changed; e.g. # their mac set, priority set, etc. Then, they will lose carrier @@ -2891,7 +2890,7 @@ class NetworkdBridgeTests(unittest.TestCase, Utilities): # add slave to bridge, but leave it down; bridge is definitely no-carrier self.check_link_attr('test1', 'operstate', 'down') check_output('ip link set dev test1 master bridge99') - self.wait_online(['bridge99:no-carrier:no-carrier'], setup_state=None) + self.wait_operstate('bridge99', operstate='no-carrier', setup_state=None) self.check_link_attr('bridge99', 'carrier', '0') elif test == 'slave-up': # bring up slave, which will have carrier; bridge gains carrier @@ -2915,7 +2914,6 @@ class NetworkdBridgeTests(unittest.TestCase, Utilities): self.check_link_attr('bridge99', 'carrier', '0') output = check_output(*networkctl_cmd, '-n', '0', 'status', 'bridge99', env=env) - print(output) self.assertRegex(output, '10.1.2.3') self.assertRegex(output, '10.1.2.1') |