From c122db238dc36d58d5ca3ed7d48d83f1cfb7d54f Mon Sep 17 00:00:00 2001 From: Jozef Behran Date: Tue, 29 Sep 2015 16:32:17 +0200 Subject: [PATCH] Fixed inconsistent line endings in text files I found some .robot files with Microsoft-style line endings which are removed by the "tidy" tool, creating unwanted noise in the form of making it appear that every line was changed. To make sure this is not going to happen anymore a .gitattributes file was added that declares the .robot files and a large bunch of other files to be text and specifies that the line endings shall be normalized using the "auto" algorithm unless the user configures his Git differently. Change-Id: I653c691759aad7baccea2e6d4266254a072cbfe1 Signed-off-by: Jozef Behran --- .gitattributes | 65 +++++ .../010__lacp_inventory.robot | 174 ++++++------- .../020__lacp_lag_resiliency.robot | 230 +++++++++--------- .../030__lacp_flow_entry_stats.robot | 124 +++++----- 4 files changed, 329 insertions(+), 264 deletions(-) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000000..f55064673d --- /dev/null +++ b/.gitattributes @@ -0,0 +1,65 @@ +# Set the default behavior, in case people don't have core.autocrlf set. +* text=auto + +# Denote all files that are truly binary and should not be modified. +*.png binary +*.jpg binary +*.gif binary +*.jar binary +*.ico binary +*.dat binary +*MessagesData binary +*TestData binary + +# Explicitly declare text files you want to always be normalized and +# converted to native line endings on checkout. Here file extensions are +# declared. +*.py text +*.txt text +*.xml text +*.robot text +*.sh text +*.conf text +*.java text +*.jsp text +*.xtend text +*.xml2 text +*.xsd text +*.yang text +*.properties text +*.html text +*.css text +*.js text +*.jj text +*.json text +*.tooling text +*.factories text +*.handlers text +*.schemas text +*.proto text +*.less text +*.bat text +*.ini text +*.cfg text +*.launch text +*.target text + +# In this section individual file names and other weird file patterns are +# declared. +COPYING text +LICENSE text +NOTICE text +README text +README.* text +README-* text +README_* text +Makefile text +.git* text +*-ok text +*-fail text +*-module text +.checkstyle text +karaf text +instance text +setenv text +RSA.pk text diff --git a/csit/suites/lacp/Lacp_Feature_OF13/010__lacp_inventory.robot b/csit/suites/lacp/Lacp_Feature_OF13/010__lacp_inventory.robot index 37ad4569ea..81066dd8d0 100644 --- a/csit/suites/lacp/Lacp_Feature_OF13/010__lacp_inventory.robot +++ b/csit/suites/lacp/Lacp_Feature_OF13/010__lacp_inventory.robot @@ -1,87 +1,87 @@ -*** Settings *** -Documentation Test suite for RESTCONF LACP inventory -Suite Setup LACP Inventory Suite Setup -Suite Teardown Delete All Sessions -Library SSHLibrary -Library Collections -Library RequestsLibrary -Library ../../../libraries/Common.py -Variables ../../../variables/Variables.py - -*** Variables *** -${node1} openflow:1 -${agg-id1} 1 -${agg-id2} 2 -${agg1-connector-id1} 1 -${agg1-connector-id2} 2 -${agg2-connector-id1} 3 -${agg2-connector-id2} 4 - -*** Test Cases *** -Get the Specific Node Inventory and Lacp aggregator details - [Documentation] Get the lacp-aggregator data for specific node - ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1} - Verify LACP RESTAPI Response Code for node - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} ${agg-id1} - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} ${agg-id2} - -Get information of each lacp-aggregator for a node - [Documentation] Get each lacp-aggregator data for a node - ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/lacp-aggregators/${agg-id1} - Verify LACP RESTAPI Response Code for node - Verify LACP connector associated for aggregator ${resp.content} ${node1} ${agg1-connector-id1} - Verify LACP connector associated for aggregator ${resp.content} ${node1} ${agg1-connector-id2} - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lag-groupid - ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/lacp-aggregators/${agg-id2} - Verify LACP RESTAPI Response Code for node - Verify LACP connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id1} - Verify LACP connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id2} - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lag-groupid - -Get node connector data for node 1 - [Documentation] Get the node connector inventory for node 1 - ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/node-connector/${node1}:${agg1-connector-id1} - Verify LACP RESTAPI Response Code for node - Verify specific LACP node connector data for node ${resp.content} ${agg-id1} agg-id - ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/node-connector/${node1}:${agg1-connector-id2} - Verify LACP RESTAPI Response Code for node - Verify specific LACP node connector data for node ${resp.content} ${agg-id1} agg-id - ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/node-connector/${node1}:${agg2-connector-id1} - Verify LACP RESTAPI Response Code for node - Verify specific LACP node connector data for node ${resp.content} ${agg-id2} agg-id - ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/node-connector/${node1}:${agg2-connector-id2} - Verify LACP RESTAPI Response Code for node - Verify specific LACP node connector data for node ${resp.content} ${agg-id2} agg-id - -*** Keywords *** -Verify LACP RESTAPI Response Code for node - [Documentation] Will check for the response code of the REST query - Should Be Equal As Strings ${resp.status_code} 200 - Should Contain ${resp.content} ${node1} - -Verify LACP RESTAPI Aggregator and Tag Contents - [Arguments] ${resp.content} ${content-lookup} - [Documentation] Will check for the LACP Specific tags or Aggregator ID for node - Should Contain ${resp.content} ${content-lookup} - -Verify LACP connector associated for aggregator - [Arguments] ${resp.content} ${node} ${agg-connector-id} - [Documentation] Will check for the LACP connector info for each aggregator - Should Contain ${resp.content} ${node}:${agg-connector-id} - -Verify specific LACP node connector data for node - [Arguments] ${resp.content} ${agg-id} ${connector} - [Documentation] Will check for node connectory info for node - Should Contain ${resp.content} ${connector}='${agg-id}' - -Verify LACP Tags Are Formed - [Documentation] Fundamental Check That LACP is working - ${resp} Get session ${OPERATIONAL_NODES_API} - Verify LACP RESTAPI Response Code for node - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} non-lag-groupid - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lacp-aggregators - -LACP Inventory Suite Setup - [Documentation] If these basic checks fail, there is no need to continue any of the other test cases - Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS} - Wait Until Keyword Succeeds 10s 1s Verify LACP Tags Are Formed +*** Settings *** +Documentation Test suite for RESTCONF LACP inventory +Suite Setup LACP Inventory Suite Setup +Suite Teardown Delete All Sessions +Library SSHLibrary +Library Collections +Library RequestsLibrary +Library ../../../libraries/Common.py +Variables ../../../variables/Variables.py + +*** Variables *** +${node1} openflow:1 +${agg-id1} 1 +${agg-id2} 2 +${agg1-connector-id1} 1 +${agg1-connector-id2} 2 +${agg2-connector-id1} 3 +${agg2-connector-id2} 4 + +*** Test Cases *** +Get the Specific Node Inventory and Lacp aggregator details + [Documentation] Get the lacp-aggregator data for specific node + ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1} + Verify LACP RESTAPI Response Code for node + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} ${agg-id1} + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} ${agg-id2} + +Get information of each lacp-aggregator for a node + [Documentation] Get each lacp-aggregator data for a node + ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/lacp-aggregators/${agg-id1} + Verify LACP RESTAPI Response Code for node + Verify LACP connector associated for aggregator ${resp.content} ${node1} ${agg1-connector-id1} + Verify LACP connector associated for aggregator ${resp.content} ${node1} ${agg1-connector-id2} + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lag-groupid + ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/lacp-aggregators/${agg-id2} + Verify LACP RESTAPI Response Code for node + Verify LACP connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id1} + Verify LACP connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id2} + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lag-groupid + +Get node connector data for node 1 + [Documentation] Get the node connector inventory for node 1 + ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/node-connector/${node1}:${agg1-connector-id1} + Verify LACP RESTAPI Response Code for node + Verify specific LACP node connector data for node ${resp.content} ${agg-id1} agg-id + ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/node-connector/${node1}:${agg1-connector-id2} + Verify LACP RESTAPI Response Code for node + Verify specific LACP node connector data for node ${resp.content} ${agg-id1} agg-id + ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/node-connector/${node1}:${agg2-connector-id1} + Verify LACP RESTAPI Response Code for node + Verify specific LACP node connector data for node ${resp.content} ${agg-id2} agg-id + ${resp} Get session ${OPERATIONAL_NODES_API}/node/${node1}/node-connector/${node1}:${agg2-connector-id2} + Verify LACP RESTAPI Response Code for node + Verify specific LACP node connector data for node ${resp.content} ${agg-id2} agg-id + +*** Keywords *** +Verify LACP RESTAPI Response Code for node + [Documentation] Will check for the response code of the REST query + Should Be Equal As Strings ${resp.status_code} 200 + Should Contain ${resp.content} ${node1} + +Verify LACP RESTAPI Aggregator and Tag Contents + [Arguments] ${resp.content} ${content-lookup} + [Documentation] Will check for the LACP Specific tags or Aggregator ID for node + Should Contain ${resp.content} ${content-lookup} + +Verify LACP connector associated for aggregator + [Arguments] ${resp.content} ${node} ${agg-connector-id} + [Documentation] Will check for the LACP connector info for each aggregator + Should Contain ${resp.content} ${node}:${agg-connector-id} + +Verify specific LACP node connector data for node + [Arguments] ${resp.content} ${agg-id} ${connector} + [Documentation] Will check for node connectory info for node + Should Contain ${resp.content} ${connector}='${agg-id}' + +Verify LACP Tags Are Formed + [Documentation] Fundamental Check That LACP is working + ${resp} Get session ${OPERATIONAL_NODES_API} + Verify LACP RESTAPI Response Code for node + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} non-lag-groupid + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lacp-aggregators + +LACP Inventory Suite Setup + [Documentation] If these basic checks fail, there is no need to continue any of the other test cases + Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS} + Wait Until Keyword Succeeds 10s 1s Verify LACP Tags Are Formed diff --git a/csit/suites/lacp/Lacp_Feature_OF13/020__lacp_lag_resiliency.robot b/csit/suites/lacp/Lacp_Feature_OF13/020__lacp_lag_resiliency.robot index 96f4dbcd45..04eccc1b39 100644 --- a/csit/suites/lacp/Lacp_Feature_OF13/020__lacp_lag_resiliency.robot +++ b/csit/suites/lacp/Lacp_Feature_OF13/020__lacp_lag_resiliency.robot @@ -1,115 +1,115 @@ -*** Settings *** -Documentation Test suite for LACP Link Resiliency -Suite Setup LACP Inventory Suite Setup -Suite Teardown Delete All Sessions -Library SSHLibrary -Library Collections -Library String -Library RequestsLibrary -Library ../../../libraries/Common.py -Resource ../../../libraries/Utils.robot -Variables ../../../variables/Variables.py - -*** Variables *** -${node1} openflow:1 -${agg-id1} 1 -${agg-id2} 2 -${agg1-connector-id1} 1 -${agg1-connector-id2} 2 -${agg2-connector-id1} 3 -${agg2-connector-id2} 4 - -*** Test Cases *** -Verify the Group tables data for Switch(S1) - [Documentation] Functionality would check the presence of group tables entries on OVS Switch(S1) initially - Verify Switch S1 Group Table select 1 2 up - Verify Switch S1 Group Table select 3 4 up - -Generate port down scenario of one of the LAG interface on the Host H2 side and check functionality - [Documentation] Generate the link failure on Host H2 LAG Membership-port and verify functionality - Set Host interface state h2-eth1 down - -Verify information of lacp-aggregator associated with Host H2 after link down scenario - [Documentation] Get lacp-aggregator data for node associated with Host H2 - Wait Until Keyword Succeeds 15s 1s Verify LACP aggregator data is updated post link down scenario - -Verify the Switch(S1) Group tables data after H2 link down scenario - [Documentation] Functionality to check if the corresponding group entries are updated on OVS Switch(S1) after port-down scenario on the Host H2 - Verify Switch S1 Group Table select 3 4 down - -Generate port up scenario of the LAG interface on the Host H2 side and check functionality - [Documentation] Generate the link up scenario on Host H2 LAG Membership-port and verify functionality - Set Host interface state h2-eth1 up - -Verify information of lacp-aggregator associated with Host H2 after link up scenario - [Documentation] Get lacp-aggregator data for node associated with Host H2 - Wait Until Keyword Succeeds 15s 1s Verify LACP aggregator data is updated post link up scenario - -Verify Switch(S1) Flow and Group tables data after H2 link up scenario - [Documentation] Functionality to check if the corresponding group entries are updated on OVS Switch(S1) after port-bringup scenario on the Host H2 - Verify Switch S1 Group Table select 3 4 up - -*** Keywords *** -Verify LACP RESTAPI Response Code for node - [Documentation] Will check for the response code of the REST query - Should Be Equal As Strings ${resp.status_code} 200 - Should Contain ${resp.content} ${node1} - -Verify LACP RESTAPI Aggregator and Tag Contents - [Arguments] ${resp.content} ${content-lookup} - [Documentation] Will check for the LACP Specific tags or Aggregator ID for node - Should Contain ${resp.content} ${content-lookup} - -Verify LACP RESTAPI connector associated for aggregator - [Arguments] ${resp.content} ${node} ${agg-connector-id} - [Documentation] Will check for the LACP connector info for each aggregator - Should Contain ${resp.content} ${node}:${agg-connector-id} - -Verify LACP aggregator data is updated post link down scenario - [Documentation] Functionality will verify the node conenctor data on the lacp-agg api after link down scenario - ${resp} RequestsLibrary.Get session ${OPERATIONAL_NODES_API}/node/${node1}/lacp-aggregators/${agg-id2} - Verify LACP RESTAPI Response Code for node - Verify LACP RESTAPI connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id1} - Should not Contain ${resp.content} ${node1}:${agg2-connector-id2} - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lag-groupid - -Verify LACP aggregator data is updated post link up scenario - [Documentation] Functionality will verify the node connector data on the lacp-agg api after link up scenario - ${resp} RequestsLibrary.Get session ${OPERATIONAL_NODES_API}/node/${node1}/lacp-aggregators/${agg-id2} - Verify LACP RESTAPI Response Code for node - Verify LACP RESTAPI connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id1} - Verify LACP RESTAPI connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id2} - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lag-groupid - -Verify LACP Tags Are Formed - [Documentation] Fundamental Check That LACP is working - ${resp} RequestsLibrary.Get session ${OPERATIONAL_NODES_API} - Verify LACP RESTAPI Response Code for node - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} non-lag-groupid - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lacp-aggregators - -LACP Inventory Suite Setup - [Documentation] If these basic checks fail, there is no need to continue any of the other test cases - Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS} - Wait Until Keyword Succeeds 15s 1s Verify LACP Tags Are Formed - -Set Host interface state - [Arguments] ${port-id} ${port-state} - [Documentation] Will configure the port state of the Host to either up or down - Open Connection ${MININET} prompt=${DEFAULT_LINUX_PROMPT} - Login With Public Key ${MININET_USER} ${USER_HOME}/.ssh/${SSH_KEY} any - Execute Command sudo ./m h2 - Execute Command sudo ifconfig ${port-id} ${port-state} - Execute Command sudo ifconfig ${port-id} - -Verify Switch S1 Group Table - [Arguments] ${group-type} ${port-id1} ${port-id2} ${port-id2-state} - [Documentation] Functionality to verify the presence of LACP group entries on the OVS Switch(S1) Group table - ${group_output}= Run Command on Remote System ${MININET} sudo ovs-ofctl dump-groups s1 -O OpenFlow13 ${MININET_USER} # - Log ${group_output} - Comment ${group_output} Read Until mininet> - ${result}= Get Lines Containing String ${group_output} output:${port-id1} - Should Contain ${result} type=${group-type} - Should Contain ${result} output:${port-id1} - Run Keyword If "${port-id2-state}" == "up" Should Contain ${result} output:${port-id2} ELSE Should not Contain - ... ${result} output:${port-id2} +*** Settings *** +Documentation Test suite for LACP Link Resiliency +Suite Setup LACP Inventory Suite Setup +Suite Teardown Delete All Sessions +Library SSHLibrary +Library Collections +Library String +Library RequestsLibrary +Library ../../../libraries/Common.py +Resource ../../../libraries/Utils.robot +Variables ../../../variables/Variables.py + +*** Variables *** +${node1} openflow:1 +${agg-id1} 1 +${agg-id2} 2 +${agg1-connector-id1} 1 +${agg1-connector-id2} 2 +${agg2-connector-id1} 3 +${agg2-connector-id2} 4 + +*** Test Cases *** +Verify the Group tables data for Switch(S1) + [Documentation] Functionality would check the presence of group tables entries on OVS Switch(S1) initially + Verify Switch S1 Group Table select 1 2 up + Verify Switch S1 Group Table select 3 4 up + +Generate port down scenario of one of the LAG interface on the Host H2 side and check functionality + [Documentation] Generate the link failure on Host H2 LAG Membership-port and verify functionality + Set Host interface state h2-eth1 down + +Verify information of lacp-aggregator associated with Host H2 after link down scenario + [Documentation] Get lacp-aggregator data for node associated with Host H2 + Wait Until Keyword Succeeds 15s 1s Verify LACP aggregator data is updated post link down scenario + +Verify the Switch(S1) Group tables data after H2 link down scenario + [Documentation] Functionality to check if the corresponding group entries are updated on OVS Switch(S1) after port-down scenario on the Host H2 + Verify Switch S1 Group Table select 3 4 down + +Generate port up scenario of the LAG interface on the Host H2 side and check functionality + [Documentation] Generate the link up scenario on Host H2 LAG Membership-port and verify functionality + Set Host interface state h2-eth1 up + +Verify information of lacp-aggregator associated with Host H2 after link up scenario + [Documentation] Get lacp-aggregator data for node associated with Host H2 + Wait Until Keyword Succeeds 15s 1s Verify LACP aggregator data is updated post link up scenario + +Verify Switch(S1) Flow and Group tables data after H2 link up scenario + [Documentation] Functionality to check if the corresponding group entries are updated on OVS Switch(S1) after port-bringup scenario on the Host H2 + Verify Switch S1 Group Table select 3 4 up + +*** Keywords *** +Verify LACP RESTAPI Response Code for node + [Documentation] Will check for the response code of the REST query + Should Be Equal As Strings ${resp.status_code} 200 + Should Contain ${resp.content} ${node1} + +Verify LACP RESTAPI Aggregator and Tag Contents + [Arguments] ${resp.content} ${content-lookup} + [Documentation] Will check for the LACP Specific tags or Aggregator ID for node + Should Contain ${resp.content} ${content-lookup} + +Verify LACP RESTAPI connector associated for aggregator + [Arguments] ${resp.content} ${node} ${agg-connector-id} + [Documentation] Will check for the LACP connector info for each aggregator + Should Contain ${resp.content} ${node}:${agg-connector-id} + +Verify LACP aggregator data is updated post link down scenario + [Documentation] Functionality will verify the node conenctor data on the lacp-agg api after link down scenario + ${resp} RequestsLibrary.Get session ${OPERATIONAL_NODES_API}/node/${node1}/lacp-aggregators/${agg-id2} + Verify LACP RESTAPI Response Code for node + Verify LACP RESTAPI connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id1} + Should not Contain ${resp.content} ${node1}:${agg2-connector-id2} + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lag-groupid + +Verify LACP aggregator data is updated post link up scenario + [Documentation] Functionality will verify the node connector data on the lacp-agg api after link up scenario + ${resp} RequestsLibrary.Get session ${OPERATIONAL_NODES_API}/node/${node1}/lacp-aggregators/${agg-id2} + Verify LACP RESTAPI Response Code for node + Verify LACP RESTAPI connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id1} + Verify LACP RESTAPI connector associated for aggregator ${resp.content} ${node1} ${agg2-connector-id2} + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lag-groupid + +Verify LACP Tags Are Formed + [Documentation] Fundamental Check That LACP is working + ${resp} RequestsLibrary.Get session ${OPERATIONAL_NODES_API} + Verify LACP RESTAPI Response Code for node + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} non-lag-groupid + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lacp-aggregators + +LACP Inventory Suite Setup + [Documentation] If these basic checks fail, there is no need to continue any of the other test cases + Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS} + Wait Until Keyword Succeeds 15s 1s Verify LACP Tags Are Formed + +Set Host interface state + [Arguments] ${port-id} ${port-state} + [Documentation] Will configure the port state of the Host to either up or down + Open Connection ${MININET} prompt=${DEFAULT_LINUX_PROMPT} + Login With Public Key ${MININET_USER} ${USER_HOME}/.ssh/${SSH_KEY} any + Execute Command sudo ./m h2 + Execute Command sudo ifconfig ${port-id} ${port-state} + Execute Command sudo ifconfig ${port-id} + +Verify Switch S1 Group Table + [Arguments] ${group-type} ${port-id1} ${port-id2} ${port-id2-state} + [Documentation] Functionality to verify the presence of LACP group entries on the OVS Switch(S1) Group table + ${group_output}= Run Command on Remote System ${MININET} sudo ovs-ofctl dump-groups s1 -O OpenFlow13 ${MININET_USER} # + Log ${group_output} + Comment ${group_output} Read Until mininet> + ${result}= Get Lines Containing String ${group_output} output:${port-id1} + Should Contain ${result} type=${group-type} + Should Contain ${result} output:${port-id1} + Run Keyword If "${port-id2-state}" == "up" Should Contain ${result} output:${port-id2} ELSE Should not Contain + ... ${result} output:${port-id2} diff --git a/csit/suites/lacp/Lacp_Feature_OF13/030__lacp_flow_entry_stats.robot b/csit/suites/lacp/Lacp_Feature_OF13/030__lacp_flow_entry_stats.robot index 93c9f822d5..1ad354576a 100644 --- a/csit/suites/lacp/Lacp_Feature_OF13/030__lacp_flow_entry_stats.robot +++ b/csit/suites/lacp/Lacp_Feature_OF13/030__lacp_flow_entry_stats.robot @@ -1,62 +1,62 @@ -*** Settings *** -Documentation Test suite to verify if the PDU count for the LACP flow entry is getting updated -Suite Setup LACP Inventory Suite Setup -Suite Teardown Delete All Sessions -Library SSHLibrary -Library Collections -Library String -Library RequestsLibrary -Library ../../../libraries/Common.py -Resource ../../../libraries/Utils.robot -Variables ../../../variables/Variables.py - -*** Variables *** -${node1} openflow:1 - -*** Test Cases *** -Verify Switch S1 LACP flow entry packet hit doesn't display zero value - [Documentation] Verify the LACP flow entry packet hit stats doesn't display zero value on the Switch S1 - ${result}= Run Command On Remote System ${MININET} sudo ovs-ofctl dump-flows s1 -O OpenFlow13 - Comment ${result} Read Until mininet> - Should Not Contain ${result} n_packets=0 - Should Not Contain ${result} n_bytes=0 - -Verify Switch S1 Port stats doesn't display zero value - [Documentation] Verify the port stats for the Switch S1 doesn't display value with zero - ${result}= Run Command On Remote System ${MININET} sudo ovs-ofctl dump-ports s1 -O OpenFlow13 ${MININET_USER} # - Comment ${result} Read Until mininet> - ${port1}= Get Lines Containing String ${result} 1: - Should Not Contain ${port1} rx pkts=0 - Should Not Contain ${port1} bytes=0 - ${port2}= Get Lines Containing String ${result} 2: - Should Not Contain ${port2} rx pkts=0 - Should Not Contain ${port2} bytes=0 - ${port3}= Get Lines Containing String ${result} 3: - Should Not Contain ${port3} rx pkts=0 - Should Not Contain ${port3} bytes=0 - ${port4}= Get Lines Containing String ${result} 4: - Should Not Contain ${port4} rx pkts=0 - Should Not Contain ${port4} bytes=0 - -*** Keywords *** -Verify LACP RESTAPI Response Code for node - [Documentation] Will check for the response code of the REST query - Should Be Equal As Strings ${resp.status_code} 200 - Should Contain ${resp.content} ${node1} - -Verify LACP RESTAPI Aggregator and Tag Contents - [Arguments] ${resp.content} ${content-lookup} - [Documentation] Will check for the LACP Specific tags or Aggregator ID for node - Should Contain ${resp.content} ${content-lookup} - -Verify LACP Tags Are Formed - [Documentation] Fundamental Check That LACP is working - ${resp} RequestsLibrary.Get session ${OPERATIONAL_NODES_API} - Verify LACP RESTAPI Response Code for node - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} non-lag-groupid - Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lacp-aggregators - -LACP Inventory Suite Setup - [Documentation] If these basic checks fail, there is no need to continue any of the other test cases - Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS} - Wait Until Keyword Succeeds 15s 1s Verify LACP Tags Are Formed +*** Settings *** +Documentation Test suite to verify if the PDU count for the LACP flow entry is getting updated +Suite Setup LACP Inventory Suite Setup +Suite Teardown Delete All Sessions +Library SSHLibrary +Library Collections +Library String +Library RequestsLibrary +Library ../../../libraries/Common.py +Resource ../../../libraries/Utils.robot +Variables ../../../variables/Variables.py + +*** Variables *** +${node1} openflow:1 + +*** Test Cases *** +Verify Switch S1 LACP flow entry packet hit doesn't display zero value + [Documentation] Verify the LACP flow entry packet hit stats doesn't display zero value on the Switch S1 + ${result}= Run Command On Remote System ${MININET} sudo ovs-ofctl dump-flows s1 -O OpenFlow13 + Comment ${result} Read Until mininet> + Should Not Contain ${result} n_packets=0 + Should Not Contain ${result} n_bytes=0 + +Verify Switch S1 Port stats doesn't display zero value + [Documentation] Verify the port stats for the Switch S1 doesn't display value with zero + ${result}= Run Command On Remote System ${MININET} sudo ovs-ofctl dump-ports s1 -O OpenFlow13 ${MININET_USER} # + Comment ${result} Read Until mininet> + ${port1}= Get Lines Containing String ${result} 1: + Should Not Contain ${port1} rx pkts=0 + Should Not Contain ${port1} bytes=0 + ${port2}= Get Lines Containing String ${result} 2: + Should Not Contain ${port2} rx pkts=0 + Should Not Contain ${port2} bytes=0 + ${port3}= Get Lines Containing String ${result} 3: + Should Not Contain ${port3} rx pkts=0 + Should Not Contain ${port3} bytes=0 + ${port4}= Get Lines Containing String ${result} 4: + Should Not Contain ${port4} rx pkts=0 + Should Not Contain ${port4} bytes=0 + +*** Keywords *** +Verify LACP RESTAPI Response Code for node + [Documentation] Will check for the response code of the REST query + Should Be Equal As Strings ${resp.status_code} 200 + Should Contain ${resp.content} ${node1} + +Verify LACP RESTAPI Aggregator and Tag Contents + [Arguments] ${resp.content} ${content-lookup} + [Documentation] Will check for the LACP Specific tags or Aggregator ID for node + Should Contain ${resp.content} ${content-lookup} + +Verify LACP Tags Are Formed + [Documentation] Fundamental Check That LACP is working + ${resp} RequestsLibrary.Get session ${OPERATIONAL_NODES_API} + Verify LACP RESTAPI Response Code for node + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} non-lag-groupid + Verify LACP RESTAPI Aggregator and Tag Contents ${resp.content} lacp-aggregators + +LACP Inventory Suite Setup + [Documentation] If these basic checks fail, there is no need to continue any of the other test cases + Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS} + Wait Until Keyword Succeeds 15s 1s Verify LACP Tags Are Formed -- 2.36.6