mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-14 10:37:29 +00:00
tests: fix ospf cosmetic output
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
This commit is contained in:
parent
65980a0224
commit
9458be1aec
@ -3065,7 +3065,11 @@ def verify_rib(
|
||||
errormsg = (
|
||||
"[DUT: {}]: tag value {}"
|
||||
" is not matched for"
|
||||
" route {} in RIB \n".format(dut, _tag, st_rt,)
|
||||
" route {} in RIB \n".format(
|
||||
dut,
|
||||
_tag,
|
||||
st_rt,
|
||||
)
|
||||
)
|
||||
return errormsg
|
||||
|
||||
@ -3082,7 +3086,11 @@ def verify_rib(
|
||||
errormsg = (
|
||||
"[DUT: {}]: metric value "
|
||||
"{} is not matched for "
|
||||
"route {} in RIB \n".format(dut, metric, st_rt,)
|
||||
"route {} in RIB \n".format(
|
||||
dut,
|
||||
metric,
|
||||
st_rt,
|
||||
)
|
||||
)
|
||||
return errormsg
|
||||
|
||||
|
@ -62,7 +62,7 @@ def create_router_ospf(tgen, topo, input_dict=None, build=False, load_config=Tru
|
||||
"r1": {
|
||||
"ospf": {
|
||||
"router_id": "22.22.22.22",
|
||||
"area": [{ "id":0.0.0.0, "type": "nssa"}]
|
||||
"area": [{ "id": "0.0.0.0", "type": "nssa"}]
|
||||
}
|
||||
}
|
||||
|
||||
@ -327,7 +327,7 @@ def config_ospf_interface(tgen, topo, input_dict=None, build=False, load_config=
|
||||
"links": {
|
||||
"r2": {
|
||||
"ospf": {
|
||||
"authentication": 'message-digest',
|
||||
"authentication": "message-digest",
|
||||
"authentication-key": "ospf",
|
||||
"message-digest-key": "10"
|
||||
}
|
||||
@ -376,6 +376,7 @@ def config_ospf_interface(tgen, topo, input_dict=None, build=False, load_config=
|
||||
if data_ospf_area:
|
||||
cmd = "ip ospf area {}".format(data_ospf_area)
|
||||
config_data.append(cmd)
|
||||
|
||||
# interface ospf auth
|
||||
if data_ospf_auth:
|
||||
if data_ospf_auth == "null":
|
||||
@ -844,18 +845,22 @@ def verify_ospf_rib(
|
||||
if "routeType" not in ospf_rib_json[st_rt]:
|
||||
errormsg = (
|
||||
"[DUT: {}]: routeType missing"
|
||||
"for route {} in OSPF RIB \n".format(dut, st_rt)
|
||||
" for route {} in OSPF RIB \n".format(
|
||||
dut, st_rt
|
||||
)
|
||||
)
|
||||
return errormsg
|
||||
elif _rtype != ospf_rib_json[st_rt]["routeType"]:
|
||||
errormsg = (
|
||||
"[DUT: {}]: routeType mismatch"
|
||||
"for route {} in OSPF RIB \n".format(dut, st_rt)
|
||||
" for route {} in OSPF RIB \n".format(
|
||||
dut, st_rt
|
||||
)
|
||||
)
|
||||
return errormsg
|
||||
else:
|
||||
logger.info(
|
||||
"DUT: {}]: Found routeType {}"
|
||||
"[DUT: {}]: Found routeType {}"
|
||||
" for route {}".format(dut, _rtype, st_rt)
|
||||
)
|
||||
if tag:
|
||||
|
Loading…
Reference in New Issue
Block a user