summaryrefslogtreecommitdiff
path: root/smoketest/scripts
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2021-04-11 19:23:10 +0200
committerChristian Poessinger <christian@poessinger.com>2021-04-12 21:16:19 +0200
commit5d9238f1d7f8d19893537a8076031903e8fea271 (patch)
tree213fd704444a8ecdd75fc7c7b083adacab0870b4 /smoketest/scripts
parent46391367806834f0f8e60f0894da6b91711d51bc (diff)
downloadvyos-1x-5d9238f1d7f8d19893537a8076031903e8fea271.tar.gz
vyos-1x-5d9238f1d7f8d19893537a8076031903e8fea271.zip
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.
Diffstat (limited to 'smoketest/scripts')
-rwxr-xr-xsmoketest/scripts/cli/test_protocols_rip.py24
1 files changed, 22 insertions, 2 deletions
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)