From: Frantisek Sumsal Date: Sat, 11 Jun 2022 16:06:38 +0000 (+0200) Subject: test-network: drop unnecessary `global` X-Git-Tag: v252-rc1~816^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f4586b70b28be20f041dc4628a7485334cb2d5ad;p=thirdparty%2Fsystemd.git test-network: drop unnecessary `global` `global` is needed only when assigning a new value to the global variable; it's not necessary when modifying a mutable object (in our case we just append items to the global list). --- diff --git a/test/test-network/systemd-networkd-tests.py b/test/test-network/systemd-networkd-tests.py index 126a7426f4d..911f79f4041 100755 --- a/test/test-network/systemd-networkd-tests.py +++ b/test/test-network/systemd-networkd-tests.py @@ -295,9 +295,6 @@ def expectedFailureIfFQPIEIsNotAvailable(): return f def setUpModule(): - # pylint: disable=global-statement - global running_units - os.makedirs(network_unit_file_path, exist_ok=True) os.makedirs(networkd_conf_dropin_path, exist_ok=True) os.makedirs(networkd_ci_path, exist_ok=True) @@ -405,9 +402,6 @@ def setUpModule(): check_output('systemctl restart systemd-udevd') def tearDownModule(): - # pylint: disable=global-statement - global running_units - shutil.rmtree(networkd_ci_path) os.remove(os.path.join(udev_rules_dir, '00-debug-net.rules'))