${BGP_TOPOLOGY_URI} ${TOPOLOGY_URL}=example-ipv4-topology
${VAR_BASE_BGP} ${CURDIR}/../variables/bgpfunctional
${RIB_NAME} example-bgp-rib
-${OLD_AS_PATH} \n"as-path": {},
-${NEW_AS_PATH} ${EMPTY}
&{APP_PEER} IP=${ODL_SYSTEM_IP} BGP_RIB=${RIB_NAME}
-${NEW_IPV4_ROUTES_LINE} ${EMPTY}
-${OLD_IPV4_ROUTES_LINE} \n"bgp-inet:ipv4-routes": {},
${BGP_CONFIG_SERVER_CMD} bgp-connect -h ${ODL_SYSTEM_IP} -p 7644 add
${VPNV4_ADDR_FAMILY} vpnv4
${DISPLAY_VPN4_ALL} show-bgp --cmd "ip bgp ${VPNV4_ADDR_FAMILY} all"
Bmp_Monitor_Postcondition
[Documentation] Verifies if example-bmp-monitor data contains one peer.
[Arguments] ${session}
- ${routes_line} = CompareStream.Set_Variable_If_At_Least_Neon
- ... ${NEW_IPV4_ROUTES_LINE}
- ... ${OLD_IPV4_ROUTES_LINE}
- &{mapping} = BuiltIn.Create_Dictionary TOOL_IP=${TOOLS_SYSTEM_IP} ROUTES_LINE=${routes_line}
+ &{mapping} = BuiltIn.Create_Dictionary TOOL_IP=${TOOLS_SYSTEM_IP}
${output} = BuiltIn.Wait_Until_Keyword_Succeeds
... 10x
... 5s
Play_To_Odl_Template
[Arguments] ${totest} ${dir} ${ipv}=ipv4
- ${as_path} = CompareStream.Set_Variable_If_At_Least_Neon ${NEW_AS_PATH} ${OLD_AS_PATH}
&{adj_rib_in} = BuiltIn.Create_Dictionary
... PATH=peer\=bgp:%2F%2F${TOOLS_SYSTEM_IP}/adj-rib-in
... BGP_RIB=${RIB_NAME}
- ... AS_PATH=${as_path}
&{effective_rib_in} = BuiltIn.Create_Dictionary
... PATH=peer\=bgp:%2F%2F${TOOLS_SYSTEM_IP}/effective-rib-in
... BGP_RIB=${RIB_NAME}
- ... AS_PATH=${as_path}
- &{loc_rib} = BuiltIn.Create_Dictionary PATH=loc-rib BGP_RIB=${RIB_NAME} AS_PATH=${as_path}
+ &{loc_rib} = BuiltIn.Create_Dictionary PATH=loc-rib BGP_RIB=${RIB_NAME}
${announce_hex} = OperatingSystem.Get_File ${dir}/${totest}/announce_${totest}.hex
${withdraw_hex} = OperatingSystem.Get_File ${dir}/${totest}/withdraw_${totest}.hex
BgpRpcClient.play_clean
${announce_hex} = OperatingSystem.Get_File ${dir}/${totest}/announce_${totest}.hex
BgpRpcClient.play_clean
BgpRpcClient.play_send ${announce_hex}
- ${as_path} = CompareStream.Set_Variable_If_At_Least_Neon ${NEW_AS_PATH} ${OLD_AS_PATH}
- &{loc_rib} = BuiltIn.Create_Dictionary PATH=loc-rib BGP_RIB=${RIB_NAME} AS_PATH=${as_path}
+ &{loc_rib} = BuiltIn.Create_Dictionary PATH=loc-rib BGP_RIB=${RIB_NAME}
BuiltIn.Wait_Until_Keyword_Succeeds
... 3x
... 2s
[Documentation] Check device is not in operational inventory or topology in all cluster instances in ${controller_index_list}.
[Arguments] ${controller_index_list}=${EMPTY}
${dictionary}= Create Dictionary openflow=0
- CompareStream.Run_Keyword_If_At_Least_Neon
- ... Wait Until Keyword Succeeds
+ Wait Until Keyword Succeeds
... 5s
... 1s
... ClusterManagement.Check_No_Content_Member_List_Or_All
... uri=${RFC8040_OPERATIONAL_NODES_API}
... member_index_list=${controller_index_list}
- CompareStream.Run_Keyword_If_At_Most_Fluorine
- ... Wait Until Keyword Succeeds
- ... 5s
- ... 1s
- ... ClusterManagement.Check_Item_Occurrence_Member_List_Or_All
- ... uri=${RFC8040_OPERATIONAL_NODES_API}
- ... dictionary=${dictionary}
- ... member_index_list=${controller_index_list}
${dictionary}= Create Dictionary openflow=0
Wait Until Keyword Succeeds
... 20s
*** Variables ***
&{Stream_dict}
-... fluorine=${9}
... neon=${10}
... sodium=${11}
... magnesium=${12}
... ${value_if_true}
... ${value_if_false}
-Set_Variable_If_At_Least_Neon
- [Documentation] Compare neon to ${ODL_STREAM} and return ${value_if_true} if ${ODL_STREAM} is at least neon,
- ... return ${value_if_false} otherwise.
- [Arguments] ${value_if_true} ${value_if_false}
- BuiltIn.Run_Keyword_And_Return Set_Variable_If_At_Least neon ${value_if_true} ${value_if_false}
-
Set_Variable_If_At_Least_Sodium
- [Documentation] Compare neon to ${ODL_STREAM} and return ${value_if_true} if ${ODL_STREAM} is at least sodium,
+ [Documentation] Compare sodium to ${ODL_STREAM} and return ${value_if_true} if ${ODL_STREAM} is at least sodium,
... return ${value_if_false} otherwise.
[Arguments] ${value_if_true} ${value_if_false}
BuiltIn.Run_Keyword_And_Return Set_Variable_If_At_Least sodium ${value_if_true} ${value_if_false}
[Arguments] ${value_if_true} ${value_if_false}
BuiltIn.Run_Keyword_And_Return Set_Variable_If_At_Least chlorine ${value_if_true} ${value_if_false}
-Set_Variable_If_At_Most_Fluorine
- [Documentation] Compare fluorine to ${ODL_STREAM} and return ${value_if_true} if ${ODL_STREAM} is at most fluorine,
- ... return ${value_if_false} otherwise.
- [Arguments] ${value_if_true} ${value_if_false}
- BuiltIn.Run_Keyword_And_Return Set_Variable_If_At_Most fluorine ${value_if_true} ${value_if_false}
-
Set_Variable_If_At_Most_Neon
[Documentation] Compare neon to ${ODL_STREAM} and return ${value_if_true} if ${ODL_STREAM} is at most neon,
... return ${value_if_false} otherwise.
BuiltIn.Run_Keyword_And_Return Set_Variable_If_At_Most neon ${value_if_true} ${value_if_false}
Set_Variable_If_At_Most_Sodium
- [Documentation] Compare neon to ${ODL_STREAM} and return ${value_if_true} if ${ODL_STREAM} is at most sodium,
+ [Documentation] Compare sodium to ${ODL_STREAM} and return ${value_if_true} if ${ODL_STREAM} is at most sodium,
... return ${value_if_false} otherwise.
[Arguments] ${value_if_true} ${value_if_false}
BuiltIn.Run_Keyword_And_Return Set_Variable_If_At_Most sodium ${value_if_true} ${value_if_false}
... @{varargs}
... &{kwargs}
-Run_Keyword_If_At_Least_Neon
- [Documentation] Compare neon to ${ODL_STREAM} and in case ${ODL_STREAM} is at least neon,
- ... run ${kw_name} @{varargs} &{kwargs} and return its value.
- [Arguments] ${kw_name} @{varargs} &{kwargs}
- BuiltIn.Run_Keyword_And_Return Run_Keyword_If_At_Least neon ${kw_name} @{varargs} &{kwargs}
-
Run_Keyword_If_At_Least_Sodium
[Documentation] Compare sodium to ${ODL_STREAM} and in case ${ODL_STREAM} is at least sodium,
... run ${kw_name} @{varargs} &{kwargs} and return its value.
[Arguments] ${kw_name} @{varargs} &{kwargs}
BuiltIn.Run_Keyword_And_Return Run_Keyword_If_At_Least chlorine ${kw_name} @{varargs} &{kwargs}
-Run_Keyword_If_At_Most_Fluorine
- [Documentation] Compare fluorine to ${ODL_STREAM} and in case ${ODL_STREAM} is at most fluroine,
- ... run ${kw_name} @{varargs} &{kwargs} and return its value.
- [Arguments] ${kw_name} @{varargs} &{kwargs}
- BuiltIn.Run_Keyword_And_Return Run_Keyword_If_At_Most fluorine ${kw_name} @{varargs} &{kwargs}
-
Run_Keyword_If_At_Most_Neon
[Documentation] Compare neon to ${ODL_STREAM} and in case ${ODL_STREAM} is at most neon,
... run ${kw_name} @{varargs} &{kwargs} and return its value.
[Arguments] ${kw_name} @{varargs} &{kwargs}
BuiltIn.Run_Keyword_And_Return Run_Keyword_If_At_Most chlorine ${kw_name} @{varargs} &{kwargs}
-Run_Keyword_If_More_Than_Fluorine
- [Documentation] Compare fluorine to ${ODL_STREAM} and in case ${ODL_STREAM} is more than fluorine,
- ... run ${kw_name} @{varargs} &{kwargs} and return its value.
- [Arguments] ${kw_name} @{varargs} &{kwargs}
- BuiltIn.Run_Keyword_And_Return Run_Keyword_If_More_Than fluorine ${kw_name} @{varargs} &{kwargs}
-
Run_Keyword_If_More_Than_Neon
[Documentation] Compare neon to ${ODL_STREAM} and in case ${ODL_STREAM} is more than neon,
... run ${kw_name} @{varargs} &{kwargs} and return its value.
[Arguments] ${kw_name} @{varargs} &{kwargs}
BuiltIn.Run_Keyword_And_Return Run_Keyword_If_More_Than chlorine ${kw_name} @{varargs} &{kwargs}
-Run_Keyword_If_Less_Than_Neon
- [Documentation] Compare neon to ${ODL_STREAM} and in case ${ODL_STREAM} is less than neon,
- ... run ${kw_name} @{varargs} &{kwargs} and return its value.
- [Arguments] ${kw_name} @{varargs} &{kwargs}
- BuiltIn.Run_Keyword_And_Return Run_Keyword_If_Less_Than neon ${kw_name} @{varargs} &{kwargs}
-
Run_Keyword_If_Less_Than_Sodium
[Documentation] Compare sodium to ${ODL_STREAM} and in case ${ODL_STREAM} is less than sodium,
... run ${kw_name} @{varargs} &{kwargs} and return its value.
${DIR_WITH_TEMPLATES} ${CURDIR}/../../../variables/bgpclustering/${ODL_STREAM}
${PCC_LOG_FILE} pccmock.restart.log
${CONFIG_SESSION} session
-${OLD_ERROR_ARGS} \n"last-received-error": {},\n"last-sent-error": {},
-${NEW_ERROR_ARGS} ${EMPTY}
+${ERROR_ARGS} ${EMPTY}
*** Test Cases ***
${code}= Evaluate binascii.b2a_base64('${pcc_name}')[:-1] modules=binascii
BuiltIn.Set_Suite_Variable ${pcc_name_code} ${code}
PcepOperations.Pcep_Topology_Precondition ${CONFIG_SESSION}
- ${ERROR_ARGS}= CompareStream.Set_Variable_If_At_Least_Neon ${NEW_ERROR_ARGS} ${OLD_ERROR_ARGS}
- BuiltIn.Set_Suite_Variable ${ERROR_ARGS}
Start_Pcc_Mock
Teardown_Everything
${DIR_WITH_TEMPLATES} ${CURDIR}/../../../variables/bgpclustering/${ODL_STREAM}
${PCC_LOG_FILE} pccmock.stop.log
${CONFIG_SESSION} session
-${OLD_ERROR_ARGS} \n"last-received-error": {},\n"last-sent-error": {},
-${NEW_ERROR_ARGS} ${EMPTY}
+${ERROR_ARGS} ${EMPTY}
*** Test Cases ***
${code}= Evaluate binascii.b2a_base64('${pcc_name}')[:-1] modules=binascii
BuiltIn.Set_Suite_Variable ${pcc_name_code} ${code}
PcepOperations.Pcep_Topology_Precondition ${CONFIG_SESSION}
- ${ERROR_ARGS}= CompareStream.Set_Variable_If_At_Least_Neon ${NEW_ERROR_ARGS} ${OLD_ERROR_ARGS}
- BuiltIn.Set_Suite_Variable ${ERROR_ARGS}
Start_Pcc_Mock
Teardown_Everything
${BGP_VARIABLES_FOLDER} ${CURDIR}/../../../variables/bgpflowspec/
${CMD} env exabgp.tcp.port=1790 exabgp --debug
${HOLDTIME} 180
-${OLD_AS_PATH} \n"as-path": {},
-${NEW_AS_PATH} ${EMPTY}
${EXP0} {"bgp-flowspec:flowspec-routes": {}}
${CFG1} bgp-flowspec.cfg
${EXP1} bgp_flowspec
SSHKeywords.Virtual_Env_Install_Package exabgp==3.4.16
RequestsLibrary.Create_Session ${CONFIG_SESSION} http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH}
Upload_Config_Files ${BGP_VARIABLES_FOLDER}
- ${AS_PATH} CompareStream.Set_Variable_If_At_Least_Neon ${NEW_AS_PATH} ${OLD_AS_PATH}
- BuiltIn.Set_Suite_Variable ${AS_PATH}
Stop_Suite
[Documentation] Suite teardown keyword
Verify_Empty_Flowspec_Data
[Documentation] Verify expected response.
- CompareStream.Run_Keyword_If_At_Most_Fluorine Normalize_And_Compare
- CompareStream.Run_Keyword_If_At_Least_Neon Verify_Empty_Flowspec_Data_Neon
+ Verify_Empty_Flowspec_Data_Neon
Verify_Flowspec_Data
[Documentation] Verify expected response
[Arguments] ${exprspdir}
- &{mapping} BuiltIn.Create_Dictionary AS_PATH=${AS_PATH}
TemplatedRequests.Get_As_Json_Templated
... ${BGP_VARIABLES_FOLDER}${/}${exprspdir}
... session=${CONFIG_SESSION}
- ... mapping=${mapping}
... verify=True
Normalize_And_Compare
${L3VPN_EXP} exa_expected
${L3VPN_RSP} bgp_l3vpn_ipv4
${L3VPN_RSPEMPTY} bgp_l3vpn_ipv4_empty
-${OLD_AS_PATH} \n"as-path": {},
-${NEW_AS_PATH} ${EMPTY}
${PLAY_SCRIPT} ${CURDIR}/../../../../tools/fastbgp/play.py
${RIB_INSTANCE} example-bgp-rib
${RT_CONSTRAIN_DIR} ${CURDIR}/../../../variables/bgpfunctional/rt_constrain
SSHKeywords.Virtual_Env_Install_Package exabgp==3.4.16
RequestsLibrary.Create_Session ${CONFIG_SESSION} http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH}
Upload_Config_Files
- ${AS_PATH} CompareStream.Set_Variable_If_At_Least_Neon ${NEW_AS_PATH} ${OLD_AS_PATH}
- BuiltIn.Set_Suite_Variable ${AS_PATH}
Stop_Suite
[Documentation] Suite teardown keyword
Verify_Empty_Reported_Data
[Documentation] Verfiy empty data response
- CompareStream.Run_Keyword_If_At_Most_Fluorine
- ... TemplatedRequests.Get_As_Json_Templated
- ... ${BGP_L3VPN_DIR}${/}${L3VPN_RSPEMPTY}
- ... session=${CONFIG_SESSION}
- ... verify=True
- CompareStream.Run_Keyword_If_At_Least_Neon Verify_Empty_Data_Neon
+ Verify_Empty_Data_Neon
Verify_Reported_Data
[Documentation] Verifies expected response
[Arguments] ${exprspdir}
- &{mapping} BuiltIn.Create_Dictionary AS_PATH=${AS_PATH}
TemplatedRequests.Get_As_Json_Templated
... ${BGP_L3VPN_DIR}${/}${exprspdir}
- ... mapping=${mapping}
... session=${CONFIG_SESSION}
... verify=True
[Setup] Configure_Path_Selection_And_App_Peer_And_Connect_Peer ${ALLPATHS_SELM} ${ADDPATHCAP_SR}
Log_Loc_Rib_Operational
Comment From neon onwards there is extra BGP End-Of-RIB message
- ${update_messages} CompareStream.Set_Variable_If_At_Most_Fluorine 3 4
+ ${update_messages} BuiltIn.Set_Variable 4
BuiltIn.Wait_Until_Keyword_Succeeds 6x 2s Verify_Expected_Update_Count ${update_messages}
[Teardown] Remove_Odl_And_App_Peer_Configuration_And_Stop_ExaBgp
[Setup] Configure_Path_Selection_And_App_Peer_And_Connect_Peer ${NPATHS_SELM} ${ADDPATHCAP_SR}
Log_Loc_Rib_Operational
Comment From neon onwards there is extra BGP End-Of-RIB message
- ${update_messages} CompareStream.Set_Variable_If_At_Most_Fluorine 2 3
+ ${update_messages} BuiltIn.Set_Variable 3
BuiltIn.Wait_Until_Keyword_Succeeds 6x 2s Verify_Expected_Update_Count ${update_messages}
[Teardown] Remove_Odl_And_App_Peer_Configuration_And_Stop_ExaBgp
${EVPN_DIR} ${CURDIR}/../../../variables/bgpfunctional/l2vpn_evpn
${BGP_TOOL_LOG_LEVEL} debug
${PLAY_SCRIPT} ${CURDIR}/../../../../tools/fastbgp/play.py
-${OLD_EVPN_ROUTES_LINE} \n"odl-bgp-evpn:evpn-routes": {},
-${NEW_EVPN_ROUTES_LINE} ${EMPTY}
-${OLD_AS_PATH} ,\n"as-path": {}
-${NEW_AS_PATH} ${EMPTY}
*** Test Cases ***
BuiltIn.Set_Suite_Variable
... ${EVPN_FAMILY_LOC_RIB}
... /rests/data/bgp-rib:bgp-rib/rib=${RIB_NAME}/loc-rib/tables=odl-bgp-evpn%3Al2vpn-address-family,odl-bgp-evpn%3Aevpn-subsequent-address-family?content=nonconfig
- ${evpn_routes_line} = CompareStream.Set_Variable_If_At_Least_Neon
- ... ${NEW_EVPN_ROUTES_LINE}
- ... ${OLD_EVPN_ROUTES_LINE}
- &{mapping} = BuiltIn.Create_Dictionary EVPN_ROUTES=${evpn_routes_line}
${EMPTY_ROUTES} = TemplatedRequests.Resolve_Text_From_Template_File
... ${EVPN_DIR}/empty_routes
... empty_routes.json
- ... ${mapping}
BuiltIn.Set_Suite_Variable ${EMPTY_ROUTES}
Stop_Suite
Play_To_Odl_Template
[Arguments] ${totest}
${data_xml} = OperatingSystem.Get_File ${EVPN_DIR}/${totest}/${totest}.xml
- ${AS_PATH} = CompareStream.Set_Variable_If_At_Least_Neon ${NEW_AS_PATH} ${OLD_AS_PATH}
- &{mapping} = BuiltIn.Create_Dictionary AS_PATH=${AS_PATH}
${data_json} = TemplatedRequests.Resolve_Text_From_Template_File
... ${EVPN_DIR}/${totest}
... ${totest}.json
- ... ${mapping}
${announce_hex} = OperatingSystem.Get_File ${EVPN_DIR}/${totest}/announce_${totest}.hex
${withdraw_hex} = OperatingSystem.Get_File ${EVPN_DIR}/${totest}/withdraw_${totest}.hex
BuiltIn.Log ${data_xml}
BgpRpcClient.exa_clean_received_update_count
BgpRpcClient.exa_announce announce route-refresh ipv4 unicast
Comment From neon onwards there are extra BGP End-Of-RIB message
- ${update_count} CompareStream.Set_Variable_If_At_Most_Fluorine 2 3
+ ${update_count} BuiltIn.Set_Variable 3
BuiltIn.Wait_Until_Keyword_Succeeds 5x 2s Verify_ExaBgp_Received_Updates ${update_count}
Comment From neon onwards there are extra BGP End-Of-RIB message per address family
- ${update_count} CompareStream.Set_Variable_If_At_Most_Fluorine 4 7
+ ${update_count} BuiltIn.Set_Variable 7
BuiltIn.Wait_Until_Keyword_Succeeds
... 3x
... 5s
... session=${CONFIG_SESSION}
BuiltIn.Wait_Until_Keyword_Succeeds 5x 2s Verify_ExaBgp_Received_Route_Refresh 1
Comment From neon onwards there are extra BGP End-Of-RIB message per address family
- ${update_count} CompareStream.Set_Variable_If_At_Most_Fluorine 4 9
+ ${update_count} BuiltIn.Set_Variable 9
BuiltIn.Wait_Until_Keyword_Succeeds
... 3x
... 5s
END
ExaBgpLib.Start_ExaBgp_And_Verify_Connected ${cfg_file} ${CONFIG_SESSION} ${TOOLS_SYSTEM_IP}
Comment From neon onwards there are extra BGP End-Of-RIB message per address family
- ${update_count} CompareStream.Set_Variable_If_At_Most_Fluorine 2 4
+ ${update_count} BuiltIn.Set_Variable 4
BuiltIn.Wait_Until_Keyword_Succeeds 3x 3s Verify_ExaBgp_Received_Updates ${update_count}
Deconfigure_Routes_And_Stop_ExaBgp
*** Variables ***
-${CONFIG_SESSION} config-session
-${BGP_BMP_DIR} ${CURDIR}/../../../variables/bgpfunctional/bmp_basic/filled_structure
-${BGP_BMP_FEAT_DIR} ${CURDIR}/../../../variables/bgpfunctional/bmp_basic/empty_structure
-${BMP_LOG_FILE} bmpmock.log
-${NEW_IPV4_ROUTES_LINE} ${EMPTY}
-${OLD_IPV4_ROUTES_LINE} \n"bgp-inet:ipv4-routes": {},
+${CONFIG_SESSION} config-session
+${BGP_BMP_DIR} ${CURDIR}/../../../variables/bgpfunctional/bmp_basic/filled_structure
+${BGP_BMP_FEAT_DIR} ${CURDIR}/../../../variables/bgpfunctional/bmp_basic/empty_structure
+${BMP_LOG_FILE} bmpmock.log
*** Test Cases ***
Verify Data Reported
[Documentation] Verifies if the tool reported expected data
- ${IPV4_ROUTES_LINE}= CompareStream.Set_Variable_If_At_Least_Neon
- ... ${NEW_IPV4_ROUTES_LINE}
- ... ${OLD_IPV4_ROUTES_LINE}
- &{mapping}= BuiltIn.Create_Dictionary TOOL_IP=${TOOLS_SYSTEM_IP} ROUTES_LINE=${IPV4_ROUTES_LINE}
+ &{mapping}= BuiltIn.Create_Dictionary TOOL_IP=${TOOLS_SYSTEM_IP}
BuiltIn.Wait_Until_Keyword_Succeeds
... 3x
... 2s
${ODL_2_IP} 127.0.0.2
${ODL_3_IP} 127.0.0.3
${ODL_4_IP} 127.0.0.4
-${OLD_AS_PATH} \n"as-path": {},
-${NEW_AS_PATH} ${EMPTY}
@{BGP_PEER_TYPES} external internal internal
@{BGP_PEER_AS_NUMBERS} 65000 64496 64496
@{ODL_IP_INDICES_ALL} 2 3 4
&{effective_rib_in} = BuiltIn.Create_Dictionary
... PATH=peer\=bgp:%2F%2F${ODL_2_IP}/effective-rib-in
... BGP_RIB=${RIB_NAME}
- ... AS_PATH=${AS_PATH}
BuiltIn.Wait_Until_Keyword_Succeeds
... 3x
... 2s
Play_To_Odl_rt_constrain_type_0
[Documentation] Sends RT route from node 2 to odl and then checks that odl advertizes l3vpn route from previous TC.
Play_To_Odl_Non_Removal_BgpRpcClient3 rt_constrain_type_0 ${RT_CONSTRAIN_DIR}
- &{loc_rib} = BuiltIn.Create_Dictionary PATH=loc-rib BGP_RIB=${RIB_NAME} AS_PATH=${AS_PATH}
+ &{loc_rib} = BuiltIn.Create_Dictionary PATH=loc-rib BGP_RIB=${RIB_NAME}
BuiltIn.Wait_Until_Keyword_Succeeds
... 3x
... 2s
&{effective_rib_in} = BuiltIn.Create_Dictionary
... PATH=peer\=bgp:%2F%2F${ODL_4_IP}/effective-rib-in
... BGP_RIB=${RIB_NAME}
- ... AS_PATH=${AS_PATH}
BuiltIn.Wait_Until_Keyword_Succeeds
... 3x
... 2s
... session=${CONFIG_SESSION}
... verify=True
${update} = BgpRpcClient4.play_get
- Comment From neon onwards there is extra BGP End-Of-RIB message
- CompareStream.Run_Keyword_If_At_Most_Fluorine BuiltIn.Should_Be_Equal ${update} ${Empty}
Play_To_Odl_remove_rt
[Documentation] Removes RT from odl and then checks that second node withdrew l3vpn route and third node did not receive any message.
BgpRpcClient3.play_clean
Play_To_Odl_Routes_Removal_Template_BgpRpcClient3 rt_constrain_type_0 ${RT_CONSTRAIN_DIR}
- Comment From neon onwards there is extra BGP End-Of-RIB message
- CompareStream.Run_Keyword_If_At_Most_Fluorine
- ... BuiltIn.Wait_Until_Keyword_Succeeds
- ... 3x
- ... 2s
- ... Verify_Empty_Reported_Data
- ${update} = BgpRpcClient4.play_get
- Comment From neon onwards there is extra BGP End-Of-RIB message
- CompareStream.Run_Keyword_If_At_Most_Fluorine BuiltIn.Should_Be_Equal ${update} ${Empty}
Play_To_Odl_remove_routes
[Documentation] Removes rt arguments from odl.
RequestsLibrary.Create_Session ${CONFIG_SESSION} http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH}
SSHLibrary.Put_File ${PLAY_SCRIPT} .
SSHKeywords.Assure_Library_Ipaddr target_dir=.
- ${AS_PATH} = CompareStream.Set_Variable_If_At_Least_Neon ${NEW_AS_PATH} ${OLD_AS_PATH}
- BuiltIn.Set_Suite_Variable ${AS_PATH}
Stop_Suite
[Documentation] Suite teardown keyword
${HOLDTIME} 180
${RIB_INSTANCE} example-bgp-rib
${CONFIG_SESSION} config-session
-${OLD_AS_PATH} \n"as-path": {},
-${NEW_AS_PATH} ${EMPTY}
*** Test Cases ***
# gets and outputs full rib output for debug purposes if one of the peers reports faulty data.
${output} TemplatedRequests.Get_As_Json_Templated ${POLICIES_VAR}/rib_state session=${CONFIG_SESSION}
BuiltIn.Log ${output}
- ${AS_PATH} CompareStream.Set_Variable_If_At_Least_Neon ${NEW_AS_PATH} ${OLD_AS_PATH}
FOR ${index} IN @{NUMBERS}
- &{mapping} BuiltIn.Create_Dictionary IP=127.0.0.${index} AS_PATH=${AS_PATH}
+ &{mapping} BuiltIn.Create_Dictionary IP=127.0.0.${index}
BuiltIn.Wait_Until_Keyword_Succeeds
... 5x
... 3s
... session=${CONFIG_SESSION}
... verify=True
END
- &{mapping} BuiltIn.Create_Dictionary IP=${ODL_SYSTEM_IP} AS_PATH=${AS_PATH}
+ &{mapping} BuiltIn.Create_Dictionary IP=${ODL_SYSTEM_IP}
# application peer verification
BuiltIn.Wait_Until_Keyword_Succeeds
... 5x
[Tags] critical
SSHLibrary.Switch Connection bgp_peer1_console
Comment From neon onwards there is extra BGP End-Of-RIB message
- ${update_messages} CompareStream.Set_Variable_If_At_Most_Fluorine 0 1
+ ${update_messages} BuiltIn.Set_Variable 1
BuiltIn.Wait_Until_Keyword_Succeeds
... ${DEFAULT_LOG_CHECK_TIMEOUT}
... ${DEFAULT_LOG_CHECK_PERIOD}
SSHLibrary.Switch Connection bgp_peer2_console
${log_check_timeout} DateTime.Convert_Time ${DEFAULT_LOG_CHECK_TIMEOUT} result_format=number
Comment From neon onwards there is extra BGP End-Of-RIB message
- ${update_messages} CompareStream.Set_Variable_If_At_Most_Fluorine 0 1
+ ${update_messages} BuiltIn.Set_Variable 1
BuiltIn.Wait_Until_Keyword_Succeeds
... ${log_check_timeout*2}
... ${DEFAULT_LOG_CHECK_PERIOD}
Library OperatingSystem
Library RequestsLibrary
Library SSHLibrary prompt=]>
-Resource ../../../libraries/CompareStream.robot
Resource ../../../libraries/FailFast.robot
Resource ../../../libraries/KarafKeywords.robot
Resource ../../../libraries/NexusKeywords.robot
*** Variables ***
${DIR_WITH_TEMPLATES} ${CURDIR}/../../../variables/tcpmd5user/${ODL_STREAM}
${CONFIG_SESSION} session
-${OLD_ERROR_ARGS} \n"last-received-error": {},\n"last-sent-error": {},
-${NEW_ERROR_ARGS} ${EMPTY}
+${ERROR_ARGS} ${EMPTY}
*** Test Cases ***
BuiltIn.Set_Suite_Variable ${filename} ${name}
#Setting Pcc Name and its code for mapping for templates
FailFast.Do_Not_Fail_Fast_From_Now_On
- ${ERROR_ARGS} CompareStream.Set_Variable_If_At_Least_Neon ${NEW_ERROR_ARGS} ${OLD_ERROR_ARGS}
- BuiltIn.Set_Suite_Variable ${ERROR_ARGS}
Tear_It_Down
[Documentation] Download pccmock.log and Log its contents.
BFD_TC01 Verify default BFD monitoring status on Controller
[Documentation] Verify the default value of BFD monitoring \ on the Controller
- CompareStream.Run_Keyword_If_At_Least_Neon
- ... BuiltIn.Wait Until Keyword Succeeds
+ BuiltIn.Wait Until Keyword Succeeds
... 10s
... 2s
... Genius.Verify Tunnel Monitoring Status
... ${TUNNEL_MONITOR_OFF}
- CompareStream.Run_Keyword_If_Less_Than_Neon
- ... BuiltIn.Wait Until Keyword Succeeds
- ... 10s
- ... 2s
- ... Genius.Verify Tunnel Monitoring Status
- ... ${TUNNEL_MONITOR_ON}
- CompareStream.Run_Keyword_If_At_Least_Neon
- ... BuiltIn.Wait Until Keyword Succeeds
+ BuiltIn.Wait Until Keyword Succeeds
... 10s
... 2s
... Verify Config Ietf Interface Output
... ${INTERFACE_DS_MONI_FALSE}
... ${INTERFACE_DS_MONI_INT_1000}
... ${TUNNEL_MONI_PROTO}
- CompareStream.Run_Keyword_If_Less_Than_Neon
- ... BuiltIn.Wait Until Keyword Succeeds
- ... 10s
- ... 2s
- ... Verify Config Ietf Interface Output
- ... ${INTERFACE_DS_MONI_TRUE}
- ... ${INTERFACE_DS_MONI_INT_1000}
- ... ${TUNNEL_MONI_PROTO}
BFD_TC02 Enable BFD Monitoring And Verify On Controller
[Documentation] Enable BFD monitoring in branches greater than neon and verify that BFD is enabled in the controller.
- CompareStream.Run_Keyword_If_Less_Than_Neon
- ... BuiltIn.Pass Execution
- ... Test case valid only for versions Neon and above
Enable BFD And Verify ${INTERFACE_DS_MONI_INT_1000}
BFD_TC03 Verify that BFD tunnel monitoring interval is set with appropriate default value i.e.,1000
BFD_TC07 Set BFD monitoring To Default Value
[Documentation] Disable BFD monitoring(setting it to default value) and verify that BFD is disabled on the controller.
- CompareStream.Run_Keyword_If_At_Least_Neon Disable BFD And Verify
- CompareStream.Run_Keyword_If_Less_Than_Neon Enable BFD And Verify ${INTERFACE_DS_MONI_INT_5000}
+ Disable BFD And Verify
*** Keywords ***
Verify Tunnels By Enabling/Disabling BFD
[Documentation] Verify tunnel creation by enabling and disabling BFD one after another with respect to the branch in such a way default value is retained at last.
- CompareStream.Run_Keyword_If_At_Least_Neon Verify Tunnels By Enabling BFD
- CompareStream.Run_Keyword_If_At_Least_Neon Verify Tunnels By Disabling BFD
- CompareStream.Run_Keyword_If_Less_Than_Neon Verify Tunnels By Disabling BFD
- CompareStream.Run_Keyword_If_Less_Than_Neon Verify Tunnels By Enabling BFD
+ Verify Tunnels By Enabling BFD
+ Verify Tunnels By Disabling BFD
Delete and Verify VTEP
[Documentation] This Delete testcase , deletes the ITM tunnel created between 2 dpns.
Check_Device_Data_Is_Empty
[Documentation] Get the device data and make sure it is empty.
- Run_Keyword_If_Less_Than_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"></data>
- Run_Keyword_If_At_Least_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
+ Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
Invoke_Yang1.1_Action_Via_Xml_Post
[Documentation] Send a sample test data label into the device and check that the request went OK.
Check_Device_Data_Is_Empty
[Documentation] Get the device data and make sure it is empty.
- Run_Keyword_If_Less_Than_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"></data>
- Run_Keyword_If_At_Least_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
+ Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
Create_Device_Data_Label_Via_Xml
[Documentation] Send a sample test data label into the device and check that the request went OK.
Check_Device_Data_Is_Deleted
[Documentation] Get the device data and make sure it is empty again.
- Run_Keyword_If_Less_Than_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"></data>
- Run_Keyword_If_At_Least_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
+ Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
Deconfigure_Device_From_Netconf
[Documentation] Make request to deconfigure the testtool device on Netconf connector.
Check_Device_Data_Is_Empty
[Documentation] Get the device data and make sure it is empty.
- Run_Keyword_If_Less_Than_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"></data>
- Run_Keyword_If_At_Least_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
+ Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
Create_Device_Data_Label_Via_Xml
[Documentation] Send a sample test data label into the device and check that the request went OK.
Check_Device_Data_Is_Deleted
[Documentation] Get the device data and make sure it is empty again.
- Run_Keyword_If_Less_Than_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"></data>
- Run_Keyword_If_At_Least_Neon Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
+ Check_Config_Data <data xmlns\="${ODL_NETCONF_NAMESPACE}"/>
Deconfigure_Device_From_Netconf
[Documentation] Make request to deconfigure the testtool device on Netconf connector.
],
"origin": {
"value": "igp"
- },$AS_PATH
+ },
"local-pref": {
"pref": 100
}
},
"origin": {
"value": "igp"
- },$AS_PATH
+ },
"local-pref": {
"pref": 100
}
],
"origin": {
"value": "igp"
- },$AS_PATH
+ },
"local-pref": {
"pref": 100
}
},
"origin": {
"value": "igp"
- },$AS_PATH
+ },
"local-pref": {
"pref": 100
}
"bgp-inet:ipv4-routes": {
"ipv4-route": [
{
- "attributes": {$AS_PATH
+ "attributes": {
"ipv4-next-hop": {
"global": "10.11.1.1"
},
"bgp-inet:ipv4-routes": {
"ipv4-route": [
{
- "attributes": {$AS_PATH
+ "attributes": {
"communities": [
{
"as-number": 30741,
"bgp-inet:ipv4-routes": {
"ipv4-route": [
{
- "attributes": {$AS_PATH
+ "attributes": {
"ipv4-next-hop": {
"global": "12.0.255.254"
},
"route-key": "2.1.1.0/24"
},
{
- "attributes": {$AS_PATH
+ "attributes": {
"ipv4-next-hop": {
"global": "12.1.255.254"
},
"route-key": "2.2.1.0/24"
},
{
- "attributes": {$AS_PATH
+ "attributes": {
"ipv4-next-hop": {
"global": "12.3.255.254"
},
"bgp-inet:ipv4-routes": {
"ipv4-route": [
{
- "attributes": {$AS_PATH
+ "attributes": {
"extended-communities": [
{
"route-target-extended-community": {
"tables": [
{
"afi": "bgp-types:ipv4-address-family",
- "safi": "bgp-types:unicast-subsequent-address-family",$ROUTES_LINE
+ "safi": "bgp-types:unicast-subsequent-address-family",
"attributes": {
"uptodate": false
}
"tables": [
{
"afi": "bgp-types:ipv4-address-family",
- "safi": "bgp-types:unicast-subsequent-address-family",$ROUTES_LINE
+ "safi": "bgp-types:unicast-subsequent-address-family",
"attributes": {
"uptodate": false
}
"bgp-rib:tables": [
{
"afi": "odl-bgp-evpn:l2vpn-address-family",
- "safi": "odl-bgp-evpn:evpn-subsequent-address-family",$EVPN_ROUTES
+ "safi": "odl-bgp-evpn:evpn-subsequent-address-family",
"attributes": {
"uptodate": false
}
},
"ipv4-next-hop": {
"global": "199.20.166.41"
- }$AS_PATH
+ }
}
}
]
},
"ipv4-next-hop": {
"global": "199.20.166.41"
- }$AS_PATH
+ }
}
}
]
},
"ipv4-next-hop": {
"global": "199.20.166.41"
- }$AS_PATH
+ }
}
}
]
},
"ipv4-next-hop": {
"global": "199.20.166.41"
- }$AS_PATH
+ }
}
}
]
},
"ipv4-next-hop": {
"global": "199.20.166.41"
- }$AS_PATH
+ }
}
}
]
},
"ipv4-next-hop": {
"global": "199.20.166.41"
- }$AS_PATH
+ }
}
}
]
},
"ipv4-next-hop": {
"global": "199.20.166.41"
- }$AS_PATH
+ }
}
}
]
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "BBcAAhmZmZkAAQAAAAAAAAAAAAAgKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "BBcAAhmZmZkAAQUBAQEBAAAH0AAgKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "BBcAAhmZmZkAAQHyDN2An/cAFgAgKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "BBcAAhmZmZkAAQLyDN2An/cAFAAgKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "BBcAAhmZmZkAAQPyDN2An/cAB9AgKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "BBcAAhmZmZkAAQQrKysrAAAH0AAgKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQAAAAAAAAAAAAAAAAAK",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQUBAQEBAAAH0AAAAAAK",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQHyDN2An/cAFgAAAAAK",
],
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQHyDN2An/cAFgAAAAAK",
],
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQHyDN2An/cAFgAAAAAK",
],
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQHyDN2An/cAFgAAAAAK",
],
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQHyDN2An/cAFgAAAAAK",
],
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQHyDN2An/cAFgAAAAAK",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQLyDN2An/cAFAAAAAAK",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQPyDN2An/cAB9AAAAAK",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "ARYAAhmZmZkAAQQrKysrAAAH0AAAAAAK",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AxEAAhmZmZkAAQAAAAogKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AxEAAhmZmZkAAQAAAAogKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AxEAAhmZmZkAAQAAAAogKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AxEAAhmZmZkAAQAAAAogKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AxEAAhmZmZkAAQAAAAogKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AxEAAhmZmZkAAQAAAAogKysrKw==",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AhgAAhmZmZkAAQAAAAow8gzdgJ/3ICsrKys=",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AhgAAhmZmZkAAQAAAAow8gzdgJ/3ICsrKys=",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AhgAAhmZmZkAAQAAAAow8gzdgJ/3ICsrKys=",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AhgAAhmZmZkAAQAAAAow8gzdgJ/3ICsrKys=",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AhgAAhmZmZkAAQAAAAow8gzdgJ/3ICsrKys=",
},
"local-pref": {
"pref": 100
- }$AS_PATH
+ }
},
"path-id": 0,
"route-key": "AhgAAhmZmZkAAQAAAAow8gzdgJ/3ICsrKys=",
"bgp-vpn-ipv4:vpn-ipv4-routes": {
"vpn-route": [
{
- "attributes": {$AS_PATH
+ "attributes": {
"ipv4-next-hop": {
"global": "10.0.255.254"
},
"attributes": {
"ipv4-next-hop": {
"global": "127.16.0.44"
- },$AS_PATH
+ },
"extended-communities": [
{
"vrf-route-import-extended-community": {
"attributes": {
"ipv6-next-hop": {
"global": "2001:db8:1::7"
- },$AS_PATH
+ },
"extended-communities": [
{
"vrf-route-import-extended-community": {
},
"multi-exit-disc": {
"med": 0
- },$AS_PATH
+ },
"origin": {
"value": "egp"
},
},
"multi-exit-disc": {
"med": 0
- },$AS_PATH
+ },
"origin": {
"value": "egp"
},
"route-distinguisher": "172.16.0.44:101",
"orig-route-ip": "192.168.100.1"
},
- "attributes": {$AS_PATH
+ "attributes": {
"ipv6-next-hop": {
"global": "2001:db8:1::6"
},
},
"multi-exit-disc": {
"med": 0
- },$AS_PATH
+ },
"pe-distinguisher-labels-attribute": {
"pe-distinguisher-label-attribute": [
{
],
"ipv4-next-hop": {
"global": "127.1.1.1"
- },$AS_PATH
+ },
"origin": {
"value": "egp"
},
],
"ipv4-next-hop": {
"global": "127.1.1.1"
- },$AS_PATH
+ },
"origin": {
"value": "igp"
},
],
"ipv4-next-hop": {
"global": "127.1.1.1"
- },$AS_PATH
+ },
"origin": {
"value": "egp"
},
},
"multi-exit-disc": {
"med": 0
- },$AS_PATH
+ },
"origin": {
"value": "egp"
},
},
"multi-exit-disc": {
"med": 0
- },$AS_PATH
+ },
"origin": {
"value": "egp"
},
},
"multi-exit-disc": {
"med": 0
- },$AS_PATH
+ },
"origin": {
"value": "egp"
},
},
"multi-exit-disc": {
"med": 0
- },$AS_PATH
+ },
"origin": {
"value": "egp"
},
},
"multi-exit-disc": {
"med": 0
- },$AS_PATH
+ },
"origin": {
"value": "egp"
},
],
"ipv4-next-hop": {
"global": "10.0.255.254"
- },$AS_PATH
+ },
"origin": {
"value": "igp"
}
{
"route-key": "",
"path-id": 0,
- "attributes": {$AS_PATH
+ "attributes": {
"ipv4-next-hop": {
"global": "199.20.166.41"
},
"attributes": {
"ipv4-next-hop": {
"global": "199.20.166.41"
- },$AS_PATH
+ },
"origin": {
"value": "igp"
},
"attributes": {
"ipv4-next-hop": {
"global": "199.20.166.41"
- },$AS_PATH
+ },
"origin": {
"value": "igp"
},
"local-administrator": 123
}
},
- "attributes": {$AS_PATH
+ "attributes": {
"ipv4-next-hop": {
"global": "199.20.166.41"
},