#!/usr/bin/env python
+# SPDX-License-Identifier: ISC
#
# Copyright (c) 2020 by VMware, Inc. ("VMware")
# Used Copyright (c) 2018 by Network Device Education Foundation,
# Inc. ("NetDEF") in this file.
#
-# Permission to use, copy, modify, and/or distribute this software
-# for any purpose with or without fee is hereby granted, provided
-# that the above copyright notice and this permission notice appear
-# in all copies.
-#
-# THE SOFTWARE IS PROVIDED "AS IS" AND VMWARE DISCLAIMS ALL WARRANTIES
-# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
-# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL VMWARE BE LIABLE FOR
-# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY
-# DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
-# WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
-# ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
-# OF THIS SOFTWARE.
-#
"""
Following tests are covered to test multicast pim sm:
topo = tgen.json_topo
# ... and here it calls Mininet initialization functions.
- # get list of daemons needs to be started for this suite.
- daemons = topo_daemons(tgen, tgen.json_topo)
-
# Starting topology, create tmp files which are loaded to routers
# to start deamons and then start routers
- start_topology(tgen, daemons)
+ start_topology(tgen)
# Don"t run this test if we have any failure.
if tgen.routers_have_failure():
assert result is True, "Testcase {} : Failed Error: {}".format(tc_name, result)
step(
- "R2 is transit router for R3 to reach R4, mroute should have (s, g) mroute with "
+ "R2 is transit router for I1 to reach R4, mroute should have (s, g) mroute with "
"OIL towards R4, using 'show ip mroute json'"
)
step(
step("Reboot R3 node")
stop_router(tgen, "r3")
- step("After reboot of R3 verify R1 became DR, using 'show ip pim interface json'")
+ step(
+ "After reboot of R3 verify R1 continues to be DR, using 'show ip pim interface json'"
+ )
result = verify_pim_config(tgen, input_dict_dr)
assert result is True, "Testcase {} : Failed Error: {}".format(tc_name, result)
step("Reboot R2 node")
stop_router(tgen, "r2")
- step("After reboot of R2, R1 became DR verify using 'show ip pim interface json'")
+ step(
+ "After reboot of R2, R1 continues to be DR verify using 'show ip pim interface json'"
+ )
result = verify_pim_config(tgen, input_dict_dr)
assert result is True, "Testcase {} : Failed Error: {}".format(tc_name, result)
"R3 and R2 should not have any mroute and upstream , verify using "
"'show ip mroute json' 'show ip pim upstream json'"
)
- step("R1 has mroute created with OIL towards R4 , using 'show ip mroute json'")
+ step("R1 has mroute created with empty OIL, using 'show ip mroute json'")
step(
- "R1 has upstream with Join Rej Prune , verify using 'show ip pim upstream json'"
+ "R1 has upstream with Not Join, Rej Prune , verify using 'show ip pim upstream json'"
)
for data in input_dict_r1_r2: