]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
test-network: stop dnsmasq before removing links
authorYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 24 May 2019 04:38:08 +0000 (13:38 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Tue, 28 May 2019 13:21:24 +0000 (22:21 +0900)
test/test-network/systemd-networkd-tests.py

index 0d6e5284f90c259abe66b6046b4df0e22ac0e084..d809e72abc396942819a99219108bbfc2ae31ed9 100755 (executable)
@@ -1906,15 +1906,15 @@ class NetworkdNetworkDHCPClientTests(unittest.TestCase, Utilities):
         'static.network']
 
     def setUp(self):
-        self.link_remove(self.links)
         self.stop_dnsmasq(dnsmasq_pid_file)
+        self.link_remove(self.links)
 
     def tearDown(self):
-        self.link_remove(self.links)
-        self.remove_unit_from_networkd_path(self.units)
         self.stop_dnsmasq(dnsmasq_pid_file)
         self.remove_lease_file()
         self.remove_log_file()
+        self.link_remove(self.links)
+        self.remove_unit_from_networkd_path(self.units)
 
     def test_dhcp_client_ipv6_only(self):
         self.copy_unit_to_networkd_unit_path('25-veth.netdev', 'dhcp-server-veth-peer.network', 'dhcp-client-ipv6-only.network')