test-network: sleep 1s after reloading configs

As interfaces will be reconfigured asynchronously after `networkctl reload`.
So, right after `networkctl reload` is finished, interfaces may be still
in 'configured' state with the old .network files.
This commit is contained in:
Yu Watanabe 2020-12-03 14:16:41 +09:00
parent d9d6a10bce
commit 37b9c79e5d
1 changed files with 2 additions and 0 deletions

View File

@ -2242,6 +2242,7 @@ class NetworkdNetworkTests(unittest.TestCase, Utilities):
copy_unit_to_networkd_unit_path('25-address-static.network')
check_output(*networkctl_cmd, 'reload', env=env)
time.sleep(1)
self.wait_online(['dummy98:routable'])
# check all routes managed by Manager are removed
@ -2262,6 +2263,7 @@ class NetworkdNetworkTests(unittest.TestCase, Utilities):
remove_unit_from_networkd_path(['25-address-static.network'])
check_output(*networkctl_cmd, 'reload', env=env)
time.sleep(1)
self.wait_online(['dummy98:routable'])
# check all routes managed by Manager are reconfigured