From 5d9238f1d7f8d19893537a8076031903e8fea271 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sun, 11 Apr 2021 19:23:10 +0200 Subject: rip: T3328: route-map to zebra/kernel can not be removed Removing the Zebra/Linux Kernel route-map added by "set protocols rip route-map" was not removed once applied. This was because the removal must happen within the zebra daemon and not ripd. --- smoketest/scripts/cli/test_protocols_rip.py | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) (limited to 'smoketest/scripts/cli/test_protocols_rip.py') diff --git a/smoketest/scripts/cli/test_protocols_rip.py b/smoketest/scripts/cli/test_protocols_rip.py index 3406688c5..423cd811a 100755 --- a/smoketest/scripts/cli/test_protocols_rip.py +++ b/smoketest/scripts/cli/test_protocols_rip.py @@ -57,7 +57,7 @@ class TestProtocolsRIP(VyOSUnitTestSHIM.TestCase): # Check for running process self.assertTrue(process_named_running(PROCESS_NAME)) - def test_rip(self): + def test_rip_01_parameters(self): distance = '40' network_distance = '66' metric = '8' @@ -100,7 +100,7 @@ class TestProtocolsRIP(VyOSUnitTestSHIM.TestCase): # commit changes self.cli_commit() - # Verify FRR ospfd configuration + # Verify FRR ripd configuration frrconfig = self.getFRRconfig('router rip') self.assertIn(f'router rip', frrconfig) self.assertIn(f' distance {distance}', frrconfig) @@ -127,5 +127,25 @@ class TestProtocolsRIP(VyOSUnitTestSHIM.TestCase): for proto in redistribute: self.assertIn(f' redistribute {proto} metric {metric} route-map {route_map}', frrconfig) + def test_rip_02_zebra_route_map(self): + # Implemented because of T3328 + self.cli_set(base_path + ['route-map', route_map]) + # commit changes + self.cli_commit() + + # Verify FRR configuration + zebra_route_map = f'ip protocol rip route-map {route_map}' + frrconfig = self.getFRRconfig(zebra_route_map) + self.assertIn(zebra_route_map, frrconfig) + + # Remove the route-map again + self.cli_delete(base_path + ['route-map']) + # commit changes + self.cli_commit() + + # Verify FRR configuration + frrconfig = self.getFRRconfig(zebra_route_map) + self.assertNotIn(zebra_route_map, frrconfig) + if __name__ == '__main__': unittest.main(verbosity=2) -- cgit v1.2.3