From: Yu Watanabe Date: Mon, 17 Jun 2019 10:57:54 +0000 (+0900) Subject: test-network: remove all routing policy rules in specified table X-Git-Tag: v243-rc1~274^2~7 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=4ef39b49919b998d249be48500fe4adf0ea18edc;p=thirdparty%2Fsystemd.git test-network: remove all routing policy rules in specified table --- diff --git a/test/test-network/systemd-networkd-tests.py b/test/test-network/systemd-networkd-tests.py index 5e948623677..a5056029269 100755 --- a/test/test-network/systemd-networkd-tests.py +++ b/test/test-network/systemd-networkd-tests.py @@ -188,7 +188,9 @@ def remove_fou_ports(ports): def remove_routing_policy_rule_tables(tables): for table in tables: - call('ip rule del table', table, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) + rc = 0 + while rc == 0: + rc = call('ip rule del table', table, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) def remove_routes(routes): for route_type, addr in routes: