Tunnel Status As UP keyword is just verifys tunnels are Up or not.
In this we are verifying no.of tunnels created are equal to
no.of expected tunnel
Change-Id: Ib5512b3621e95a07de54aeeccf65dc3c660811c1
Signed-off-by: Sathwik Boggarapu <b.sathwik@ericsson.com>
Resource ../variables/Variables.robot
Resource OVSDB.robot
Resource ../variables/netvirt/Variables.robot
+Resource VpnOperations.robot
*** Variables ***
@{itm_created} TZA
[Documentation] Verifies the Tunnel is deleted from datastore
${resp} RequestsLibrary.Get Request session ${OPERATIONAL_API}/itm-state:tunnels_state/
Should Not Contain ${resp.content} ${tunnel1} ${tunnel2}
+
+Verify Tunnel Status as UP
+ [Documentation] Verify that the number of tunnels are UP
+ ${No_of_Teps} Issue_Command_On_Karaf_Console ${TEP_SHOW}
+ ${Lines_of_TZA} Get Lines Containing String ${No_of_Teps} TZA
+ ${Expected_Node_Count} Get Line Count ${Lines_of_TZA}
+ ${no_of_tunnels} Issue_Command_On_Karaf_Console ${TEP_SHOW_STATE}
+ ${lines_of_VXLAN} Get Lines Containing String ${no_of_tunnels} VXLAN
+ Should Contain ${no_of_tunnels} ${STATE_UP}
+ Should Not Contain ${no_of_tunnels} ${STATE_DOWN}
+ Should Not Contain ${no_of_tunnels} ${STATE_UNKNOWN}
+ ${Actual_Tunnel_Count} Get Line Count ${lines_of_VXLAN}
+ ${Expected_Tunnel_Count} Set Variable ${Expected_Node_Count*${Expected_Node_Count - 1}}
+ Should Be Equal As Strings ${Actual_Tunnel_Count} ${Expected_Tunnel_Count}
${vlan}= Set Variable 0
${gateway-ip}= Set Variable 0.0.0.0
Genius.Create Vteps ${Dpn_id_1} ${Dpn_id_2} ${TOOLS_SYSTEM_IP} ${TOOLS_SYSTEM_2_IP} ${vlan} ${gateway-ip}
- Wait Until Keyword Succeeds 30s 5s Verify Tunnel Status as UP
+ Wait Until Keyword Succeeds 30s 5s Genius.Verify Tunnel Status as UP
BFD_TC01 Verify by default BFD monitoring is enabled on Controller
[Documentation] Verify by default BFD monitoring is enabled on Controller
BFD_TC04 Verify that in controller tunnel status is up when ITM tunnel interface is brought up.
[Documentation] Verify that in controller tunnel status is up when ITM tunnel interface is brought up.
Wait Until Keyword Succeeds 10s 2s Verify Tunnel Monitoring Is On
- Wait Until Keyword Succeeds 10s 1s Verify Tunnel Status as UP
+ Wait Until Keyword Succeeds 10s 1s Genius.Verify Tunnel Status as UP
Wait Until Keyword Succeeds 10s 2s Verify Config Ietf Interface Output ${INTERFACE_DS_MONI_TRUE} ${INTERFACE_DS_MONI_INT_1000} ${TUNNEL_MONI_PROTO}
BFD_TC05 Verify BFD tunnel monitoring interval can be changed.
Log "After connecting CSS with controller"
Issue Command On Karaf Console ${TEP_SHOW}
Issue Command On Karaf Console ${TEP_SHOW_STATE}
- Wait Until Keyword Succeeds 10s 1s Verify Tunnel Status as UP
+ Wait Until Keyword Succeeds 10s 1s Genius.Verify Tunnel Status as UP
Wait Until Keyword Succeeds 10s 2s Verify Config Ietf Interface Output ${INTERFACE_DS_MONI_TRUE} ${INTERFACE_DS_MONI_INT_5000} ${TUNNEL_MONI_PROTO}
BFD_TC07 Verify that BFD monitoring is disabled on Controller
${output}= Issue Command On Karaf Console ${TEP_SHOW}
Should Contain ${output} ${TUNNEL_MONITOR_OFF}
Wait Until Keyword Succeeds 10s 2s Verify Config Ietf Interface Output ${INTERFACE_DS_MONI_FALSE} ${INTERFACE_DS_MONI_INT_5000} ${TUNNEL_MONI_PROTO}
- Wait Until Keyword Succeeds 10s 1s Verify Tunnel Status as UP
+ Wait Until Keyword Succeeds 10s 1s Genius.Verify Tunnel Status as UP
${resp} RequestsLibrary.Put Request session ${CONFIG_API}/itm-config:tunnel-monitor-params/ data=${ENABLE_MONITORING}
Should Be Equal As Strings ${resp.status_code} 200
Wait Until Keyword Succeeds 10s 2s Verify Tunnel Monitoring Params ${TUNNEL_MONI_PARAMS_TRUE}
Verify VTEP After Restarting Controller
[Documentation] Verify Testcase, Verifying tunnel state by restarting CONTROLLER
- Verify Tunnel Status as UP
+ Genius.Verify Tunnel Status as UP
ClusterManagement.Stop_Members_From_List_Or_All
ClusterManagement.Start_Members_From_List_Or_All
Wait Until Keyword Succeeds 10 2 Check Service Status ACTIVE OPERATIONAL
- Wait Until Keyword Succeeds 30 3 Verify Tunnel Status as UP
+ Wait Until Keyword Succeeds 30 3 Genius.Verify Tunnel Status as UP
Delete and Verify VTEP
[Documentation] This Delete testcase , deletes the ITM tunnel created between 2 dpns.
OVSDB.Stop OVS ${TOOLS_SYSTEM_IP}
Wait Until Keyword Succeeds 2min 20 sec Verify Tunnel Down
OVSDB.Start OVS ${TOOLS_SYSTEM_IP}
- Wait Until Keyword Succeeds 2min 20 sec Verify Tunnel Status as UP
+ Wait Until Keyword Succeeds 2min 20 sec Genius.Verify Tunnel Status as UP
Verify Tunnel Down
[Documentation] In this we will check whether tunnel is in down or not