From 321bda60d80d5c744da7d395ee0bc750e89115e7 Mon Sep 17 00:00:00 2001 From: srajappa Date: Fri, 14 Sep 2018 11:23:24 +0530 Subject: [PATCH] suite change for ITM Auto Tunnel Change-Id: I0b2230f915eb082013648a9c52d3cbac6dd83946 Signed-off-by: srajappa --- csit/suites/genius/Configure_ITM.robot | 24 ++++++++++++++++++++- csit/suites/genius/ITM_Direct_Tunnels.robot | 6 ++++++ 2 files changed, 29 insertions(+), 1 deletion(-) diff --git a/csit/suites/genius/Configure_ITM.robot b/csit/suites/genius/Configure_ITM.robot index 25a12fb552..54a8bd4dfe 100644 --- a/csit/suites/genius/Configure_ITM.robot +++ b/csit/suites/genius/Configure_ITM.robot @@ -78,14 +78,20 @@ Delete and Verify VTEP -No Vlan ${cmd} Set Variable tep:delete ${Dpn_id_1} @{PORT}[0] @{VLAN}[0] ${TOOLS_SYSTEM_IP} ${subnet}/24 null ${itm_created[0]} ${cmd2} Set Variable tep:delete ${Dpn_id_2} @{PORT}[1] @{VLAN}[0] ${TOOLS_SYSTEM_2_IP} ${subnet}/24 null ${itm_created[0]} KarafKeywords.Issue Command On Karaf Console ${cmd} + KarafKeywords.Issue Command On Karaf Console tep:commit KarafKeywords.Issue Command On Karaf Console ${cmd2} KarafKeywords.Issue Command On Karaf Console tep:commit ${output} KarafKeywords.Issue Command On Karaf Console ${TEP_SHOW} BuiltIn.Should Not Contain ${output} ${itm_created[0]} + BuiltIn.Run Keyword And Ignore Error Remove All Elements At URI And Verify ${CONFIG_API}/itm:transport-zones/transport-zone/${itm_created[0]}/ ${resp} RequestsLibrary.Get Request session ${OPERATIONAL_API}/itm-state:tunnels_state/ Should Not Contain ${resp} ${tunnel-1} ${tunnel-2} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_1} ${tunnel-1} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_2} ${tunnel-2} + ${resp} RequestsLibrary.Get Request session ${OPERATIONAL_API}/itm:not-hosted-transport-zones/ + ${respjson} RequestsLibrary.To Json ${resp.content} pretty_print=True + Log ${respjson} + BuiltIn.Should Not Contain ${resp.content} ${itm_created[0]} Create and Verify VTEP IPv6 - No Vlan [Documentation] This testcase creates a Internal Transport Manager - ITM tunnel between 2 DPNs without VLAN and Gateway configured in Json. @@ -125,11 +131,15 @@ Delete and Verify VTEP IPv6 -No Vlan Remove All Elements At URI And Verify ${CONFIG_API}/itm:transport-zones/transport-zone/${itm_created[0]}/subnets/${subnet}%2F24/vteps/${Dpn_id_2}/@{PORT}[1] ${output} KarafKeywords.Issue Command On Karaf Console ${TEP_SHOW} BuiltIn.Should Not Contain ${output} ${itm_created[0]} - Remove All Elements At URI And Verify ${CONFIG_API}/itm:transport-zones/transport-zone/${itm_created[0]}/ + BuiltIn.Run Keyword And Ignore Error Remove All Elements At URI And Verify ${CONFIG_API}/itm:transport-zones/transport-zone/${itm_created[0]}/ ${resp} RequestsLibrary.Get Request session ${OPERATIONAL_API}/itm-state:tunnels_state/ Should Not Contain ${resp} ${tunnel-1} ${tunnel-2} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_1} ${tunnel-1} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_2} ${tunnel-2} + ${resp} RequestsLibrary.Get Request session ${OPERATIONAL_API}/itm:not-hosted-transport-zones/ + ${respjson} RequestsLibrary.To Json ${resp.content} pretty_print=True + Log ${respjson} + BuiltIn.Should Not Contain ${resp.content} ${itm_created[0]} Create and Verify VTEP-Vlan [Documentation] This testcase creates a Internal Transport Manager - ITM tunnel between 2 DPNs with VLAN and \ without Gateway configured in Json. @@ -184,13 +194,19 @@ Delete and Verify VTEP -Vlan ${cmd1} Set Variable tep:delete ${Dpn_id_1} @{PORT}[0] @{VLAN}[1] ${TOOLS_SYSTEM_IP} ${subnet}/24 null ${itm_created[0]} ${cmd2} Set Variable tep:delete ${Dpn_id_2} @{PORT}[1] @{VLAN}[1] ${TOOLS_SYSTEM_2_IP} ${subnet}/24 null ${itm_created[0]} KarafKeywords.Issue Command On Karaf Console ${cmd1} + KarafKeywords.Issue Command On Karaf Console tep:commit KarafKeywords.Issue Command On Karaf Console ${cmd2} KarafKeywords.Issue Command On Karaf Console tep:commit ${output} KarafKeywords.Issue Command On Karaf Console ${TEP_SHOW} BuiltIn.Should Not Contain ${output} ${itm_created[0]} + BuiltIn.Run Keyword And Ignore Error Remove All Elements At URI And Verify ${CONFIG_API}/itm:transport-zones/transport-zone/${itm_created[0]}/ Wait Until Keyword Succeeds 40 10 Genius.Check ITM Tunnel State ${tunnel-1} ${tunnel-2} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_1} ${tunnel-1} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_2} ${tunnel-2} + ${resp} RequestsLibrary.Get Request session ${OPERATIONAL_API}/itm:not-hosted-transport-zones/ + ${respjson} RequestsLibrary.To Json ${resp.content} pretty_print=True + Log ${respjson} + BuiltIn.Should Not Contain ${resp.content} ${itm_created[0]} Create VTEP - Vlan and Gateway [Documentation] This testcase creates a Internal Transport Manager - ITM tunnel between 2 DPNs with VLAN and Gateway configured in Json. @@ -248,13 +264,19 @@ Delete VTEP -Vlan and gateway ${cmd1} Set Variable tep:delete ${Dpn_id_1} @{PORT}[0] @{VLAN}[2] ${TOOLS_SYSTEM_IP} ${subnet}/24 ${GATEWAY_IP} ${itm_created[0]} ${cmd2} Set Variable tep:delete ${Dpn_id_2} @{PORT}[1] @{VLAN}[2] ${TOOLS_SYSTEM_2_IP} ${subnet}/24 ${GATEWAY_IP} ${itm_created[0]} KarafKeywords.Issue Command On Karaf Console ${cmd1} + KarafKeywords.Issue Command On Karaf Console tep:commit KarafKeywords.Issue Command On Karaf Console ${cmd2} KarafKeywords.Issue Command On Karaf Console tep:commit ${output} KarafKeywords.Issue Command On Karaf Console ${TEP_SHOW} BuiltIn.Should Not Contain ${output} ${itm_created[0]} + BuiltIn.Run Keyword And Ignore Error Remove All Elements At URI And Verify ${CONFIG_API}/itm:transport-zones/transport-zone/${itm_created[0]}/ Wait Until Keyword Succeeds 40 10 Genius.Check ITM Tunnel State ${tunnel-1} ${tunnel-2} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_1} ${tunnel-1} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_2} ${tunnel-2} + ${resp} RequestsLibrary.Get Request session ${OPERATIONAL_API}/itm:not-hosted-transport-zones/ + ${respjson} RequestsLibrary.To Json ${resp.content} pretty_print=True + Log ${respjson} + BuiltIn.Should Not Contain ${resp.content} ${itm_created[0]} *** Keywords *** Create Vteps IPv6 diff --git a/csit/suites/genius/ITM_Direct_Tunnels.robot b/csit/suites/genius/ITM_Direct_Tunnels.robot index 3297dffd51..07768346ab 100644 --- a/csit/suites/genius/ITM_Direct_Tunnels.robot +++ b/csit/suites/genius/ITM_Direct_Tunnels.robot @@ -96,14 +96,20 @@ Delete and Verify VTEP ${cmd1} Set Variable tep:delete ${Dpn_id_1} @{PORT}[0] ${VLAN} ${TOOLS_SYSTEM_IP} ${subnet}/24 null ${itm_created[0]} ${cmd2} Set Variable tep:delete ${Dpn_id_2} @{PORT}[1] ${VLAN} ${TOOLS_SYSTEM_2_IP} ${subnet}/24 null ${itm_created[0]} KarafKeywords.Issue Command On Karaf Console ${cmd1} + KarafKeywords.Issue Command On Karaf Console tep:commit KarafKeywords.Issue Command On Karaf Console ${cmd2} KarafKeywords.Issue Command On Karaf Console tep:commit ${output} KarafKeywords.Issue Command On Karaf Console ${TEP_SHOW} BuiltIn.Should Not Contain ${output} ${itm_created[0]} + BuiltIn.Run Keyword And Ignore Error Remove All Elements At URI And Verify ${CONFIG_API}/itm:transport-zones/transport-zone/${itm_created[0]}/ ${resp} RequestsLibrary.Get Request session ${OPERATIONAL_API}/itm-state:tunnels_state/ Should Not Contain ${resp} ${tunnel-1} ${tunnel-2} ${Ovs-del-1} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_1} ${tunnel-1} ${Ovs-del-2} Wait Until Keyword Succeeds 40 10 Genius.Check Tunnel Delete On OVS ${conn_id_2} ${tunnel-2} + ${resp} RequestsLibrary.Get Request session ${OPERATIONAL_API}/itm:not-hosted-transport-zones/ + ${respjson} RequestsLibrary.To Json ${resp.content} pretty_print=True + Log ${respjson} + BuiltIn.Should Not Contain ${resp.content} ${itm_created[0]} *** Keywords *** Get_Tunnel -- 2.36.6