[Return] ${output}
Check Karaf Log File Does Not Have Messages
- [Arguments] ${ip} ${message} ${user}=${ODL_SYSTEM_USER} ${password}=${CONTROLLER_PASSWORD} ${prompt}=${DEFAULT_LINUX_PROMPT} ${log_file}=${WORKSPACE}/${BUNDLEFOLDER}/data/log/karaf.log
+ [Arguments] ${ip} ${message} ${user}=${ODL_SYSTEM_USER} ${password}=${ODL_SYSTEM_PASSWORD} ${prompt}=${DEFAULT_LINUX_PROMPT} ${log_file}=${WORKSPACE}/${BUNDLEFOLDER}/data/log/karaf.log
[Documentation] Fails if the provided ${message} is found in the karaf.log file. Uses grep to search. The
... karaf.log file can be overridden with ${log_file} to be any file on the given system @ ${ip}
${output}= Run Command On Controller ${ip} grep -c '${message}' ${log_file} user=${user} password=${password} prompt=${prompt}
...
...
... This library assumes that a SSH connections exists (and is switched to)
-... to a Linux machine (usualy MININET) where the Python process should be killed.
+... to a Linux machine (usualy TOOLS_SYSTEM_IP) where the Python process should be killed.
... TODO: The Utils.robot library has a "Run Command On Remote System" if we didn't want to make the assumption that an SSH connection was already open.
... alternative TODO: Explain that it is not worth to perform separate SSH logins.
...
*** Keywords ***
Setup Unimgr Test Environment
[Documentation] Establish the Opendayligh session and prepair the Mininet VMs
- Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+ Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Prepair Unimgr Test Environment ${TOOLS_SYSTEM_IP}
Prepair Unimgr Test Environment ${TOOLS_SYSTEM_2_IP}
*** Variables ***
# port is fixed in Jetty configuration, as well
-${URI} http://${CONTROLLER}:8282
+${URI} http://${ODL_SYSTEM_IP}:8282
# create lists for Domains, Roles and Users - that can be cleaned up upon Teardown
@{cleanup_domain_list}
@{cleanup_role_list}
*** Settings ***
Documentation Test suite for resourcepool
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Variables ../../../variables/Variables.py
*** Settings ***
Documentation Test suite for ALTO simple IRD (Information Resource Dictionary)
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Library ../../../libraries/ALTO/AltoParser.py
*** Settings ***
Documentation Test suite to verify Restconf is OK
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Library ../../../libraries/Common.py
Resource ${CURDIR}/../../../libraries/PcepOperations.robot
Resource ${CURDIR}/../../../libraries/Utils.robot
Variables ${CURDIR}/../../../variables/Variables.py
-Variables ${CURDIR}/../../../variables/pcepuser/variables.py ${MININET}
+Variables ${CURDIR}/../../../variables/pcepuser/variables.py ${TOOLS_SYSTEM_IP}
*** Variables ***
-${MININET_PROMPT} ${DEFAULT_LINUX_PROMPT}
${OUTPUT_TIMEOUT} 10
# FIXME: Unify parameter naming and case.
${ExpDir} ${CURDIR}/expected
Start_Pcc_Mock
[Documentation] Execute pcc-mock on Mininet, fail is Open is not sent, keep it running for next tests.
- ${command}= NexusKeywords.Compose_Full_Java_Command -jar ${filename} --local-address ${MININET} --remote-address ${CONTROLLER} 2>&1 | tee pccmock.log
+ ${command}= NexusKeywords.Compose_Full_Java_Command -jar ${filename} --local-address ${TOOLS_SYSTEM_IP} --remote-address ${ODL_SYSTEM_IP} 2>&1 | tee pccmock.log
Log ${command}
Write ${command}
Read_Until started, sent proposal Open
... Also, delete and create directories for json diff handling.
NexusKeywords.Initialize_Artifact_Deployment_And_Usage
# FIXME: Unify Module prefix usage across whole file.
- Create_Session ses http://${CONTROLLER}:${RESTCONFPORT}/restconf/operational/network-topology:network-topology auth=${AUTH}
+ Create_Session ses http://${ODL_SYSTEM_IP}:${RESTCONFPORT}/restconf/operational/network-topology:network-topology auth=${AUTH}
${name}= NexusKeywords.Deploy_Test_Tool bgpcep pcep-pcc-mock
BuiltIn.Set_Suite_Variable ${filename} ${name}
Remove_Directory ${ExpDir}
Resource ${CURDIR}/../../../libraries/PcepOperations.robot
Resource ${CURDIR}/../../../libraries/WaitForFailure.robot
Variables ${CURDIR}/../../../variables/Variables.py
-Variables ${CURDIR}/../../../variables/pcepuser/variables.py ${MININET}
+Variables ${CURDIR}/../../../variables/pcepuser/variables.py ${TOOLS_SYSTEM_IP}
*** Variables ***
${directory_for_actual_responses} ${TEMPDIR}${/}actual
Start_Secure_Pcc_Mock
[Documentation] Execute pcc-mock on Mininet with password set, fail if pcc-mock promptly exits. Keep pcc-mock running for next test cases.
- ${command}= NexusKeywords.Compose_Full_Java_Command -jar ${filename} --password topsecret --reconnect 1 --local-address ${MININET} --remote-address ${CONTROLLER} 2>&1 | tee pccmock.log
+ ${command}= NexusKeywords.Compose_Full_Java_Command -jar ${filename} --password topsecret --reconnect 1 --local-address ${TOOLS_SYSTEM_IP} --remote-address ${ODL_SYSTEM_IP} 2>&1 | tee pccmock.log
BuiltIn.Log ${command}
SSHLibrary.Write ${command}
Read_And_Fail_If_Prompt_Is_Seen
${current_prompt}= BuiltIn.Set_Variable ${current_connection.prompt}
BuiltIn.Log ${current_prompt}
BuiltIn.Set_Suite_Variable ${prompt} ${current_prompt}
- RequestsLibrary.Create_Session ses http://${CONTROLLER}:${RESTCONFPORT}${OPERATIONAL_TOPO_API} auth=${AUTH}
+ RequestsLibrary.Create_Session ses http://${ODL_SYSTEM_IP}:${RESTCONFPORT}${OPERATIONAL_TOPO_API} auth=${AUTH}
${name}= NexusKeywords.Deploy_Test_Tool bgpcep pcep-pcc-mock
BuiltIn.Set_Suite_Variable ${filename} ${name}
OperatingSystem.Remove_Directory ${directory_for_expected_responses} recursive=True
Replace_Password_Xml_Element_In_Pcep_Client_Module
[Arguments] ${password_element}
[Documentation] Send restconf PUT to replace the config module specifying PCEP password element (may me empty=missing).
- ${mapping_as_string}= BuiltIn.Set_Variable {'IP': '${MININET}', 'PASSWD': '''${password_element}'''}
+ ${mapping_as_string}= BuiltIn.Set_Variable {'IP': '${TOOLS_SYSTEM_IP}', 'PASSWD': '''${password_element}'''}
BuiltIn.Log ${mapping_as_string}
ConfigViaRestconf.Put_Xml_Template_Folder_Config_Via_Restconf ${directory_with_template_folders}${/}pcep_topology_client_module ${mapping_as_string}
... LOG_NAME: Filename (without path) to save pcc-mock output into.
... LOG_PATH: Override if not the same as pccmock VM workspace.
... LSPS: Number of LSPs per PCC to simulate and test.
-... MININET: Numeric IP address of VM to run pcc-mock and updater from by default.
-... MININET_PASSWORD: Linux password to go with the username (empty means keys).
-... MININET_PROMPT: Substring to identify Linux prompt on Mininet VM.
-... MININET_USER: Linux username to SSH to on Mininet VM.
+... TOOLS_SYSTEM_IP: Numeric IP address of VM to run pcc-mock and updater from by default.
+... TOOLS_SYSTEM_PASSWORD: Linux password to go with the username (empty means keys).
+... TOOLS_SYSTEM_PROMPT: Substring to identify Linux prompt on Mininet VM.
+... TOOLS_SYSTEM_USER: Linux username to SSH to on Mininet VM.
... MININET_WORKSPACE: Path to where files may be created on Mininet VM.
... MOCK_FILE: Filename to use for mock-pcc executable instead of the timestamped one.
... PCCDOWNLOAD_HOSTHEADER: Download server may check checks this header before showing content.
# This table acts as an exhaustive list of variables users can modify on pybot invocation.
# It also contains commented-out lines for variables defined elswhere.
# Keep this list in alphabetical order.
-# ${CONTROLLER} is inherited from Variables.py
-# ${CONTROLLER_USER} is inherited from Variables.py
-# ${CONTROLLER_PASSWORD} is inherited from Variables.py
-${CONTROLLER_PROMPT} ${DEFAULT_LINUX_PROMPT} # from Variables.py
${CONTROLLER_WORKSPACE} /tmp
${FIRST_PCC_IP} ${PCCMOCKVM_IP}
# ${LOG_FILE} is reserved for location of pybot-created log.html
${LOG_PATH} ${PCCMOCKVM_WORKSPACE}
${LSPS} 65535
${MININET} 127.0.0.1
-# ${MININET_PASSWORD} is inherited from Variables.py
-${MININET_PROMPT} ${DEFAULT_LINUX_PROMPT} # from Variables.py
${MININET_USER} mininet
${MININET_WORKSPACE} /tmp
${PCCDOWNLOAD_HOSTHEADER} nexus.opendaylight.org
${PCCDOWNLOAD_URLBASE} http://${PCCDOWNLOAD_HOSTHEADER}/content/repositories/opendaylight.snapshot/org/opendaylight/bgpcep/pcep-pcc-mock/
${PCCMOCK_COLOCATED} False
-${PCCMOCKVM_IP} ${MININET}
-${PCCMOCKVM_PASSWORD} ${MININET_PASSWORD}
-${PCCMOCKVM_PROMPT} ${MININET_PROMPT}
-${PCCMOCKVM_USER} ${MININET_USER}
+${PCCMOCKVM_IP} ${TOOLS_SYSTEM_IP}
+${PCCMOCKVM_PASSWORD} ${TOOLS_SYSTEM_PASSWORD}
+${PCCMOCKVM_PROMPT} ${TOOLS_SYSTEM_PROMPT}
+${PCCMOCKVM_USER} ${TOOLS_SYSTEM_USER}
${PCCMOCKVM_WORKSPACE} ${MININET_WORKSPACE}
${PCCS} 1
${PCEP_READY_VERIFY_TIMEOUT} 300s
${RESTCONF_SCOPE} ${EMPTY}
${RESTCONF_USER} ${USER} # from Variables.py
${UPDATER_COLOCATED} False
-${UPDATER_ODLADDRESS} ${CONTROLLER}
+${UPDATER_ODLADDRESS} ${OLD_SYSTEM_IP}
${UPDATER_REFRESH} 0.1
${UPDATER_TIMEOUT} 300
${UPDATERVM_ENABLE_TCP_RW_REUSE} True
-${UPDATERVM_IP} ${MININET}
-${UPDATERVM_PASSWORD} ${MININET_PASSWORD}
-${UPDATERVM_PROMPT} ${MININET_PROMPT}
+${UPDATERVM_IP} ${TOOLS_SYSTEM_IP}
+${UPDATERVM_PASSWORD} ${TOOLS_SYSTEM_PASSWORD}
+${UPDATERVM_PROMPT} ${TOOLS_SYSTEM_PROMPT}
${UPDATERVM_USER} ${MININET_USER}
${UPDATERVM_WORKSPACE} ${MININET_WORKSPACE}
SSHKeywords.Assure_Library_Counter target_dir=${UPDATERVM_WORKSPACE}
SSHKeywords.Assure_Library_Ipaddr target_dir=${UPDATERVM_WORKSPACE}
# Done preparation of Updater VM, now use AuthStandalone to create session from robot VM too.
- BuiltIn.Log_Many ${RESTCONF_USER} ${RESTCONF_PASSWORD} ${RESTCONF_SCOPE} ${CONTROLLER}
- ${session} = AuthStandalone.Init_Session ${CONTROLLER} ${RESTCONF_USER} ${RESTCONF_PASSWORD} ${RESTCONF_SCOPE}
+ BuiltIn.Log_Many ${RESTCONF_USER} ${RESTCONF_PASSWORD} ${RESTCONF_SCOPE} ${ODL_SYSTEM_IP}
+ ${session} = AuthStandalone.Init_Session ${ODL_SYSTEM_IP} ${RESTCONF_USER} ${RESTCONF_PASSWORD} ${RESTCONF_SCOPE}
BuiltIn.Set_Suite_Variable ${rest_session} ${session}
# TODO: Define http timeouts.
Start_Pcc_Mock
[Documentation] Launch pcc-mock on background so simulated PCCs start connecting to controller.
SSHLibrary.Switch_Connection pccmock
- ${command} = NexusKeywords.Compose_Full_Java_Command -jar ${mock_location} --local-address ${FIRST_PCC_IP} --remote-address ${CONTROLLER} --pcc ${PCCS} --lsp ${LSPS} &> ${LOG_PATH}/${LOG_NAME}
+ ${command} = NexusKeywords.Compose_Full_Java_Command -jar ${mock_location} --local-address ${FIRST_PCC_IP} --remote-address ${ODL_SYSTEM_IP} --pcc ${PCCS} --lsp ${LSPS} &> ${LOG_PATH}/${LOG_NAME}
BuiltIn.Log ${command}
SSHLibrary.Write ${command}
# The pccmock SSH session is left alive, but no data will be exchanged for a while.
*** Keywords ***
Pccmock_From_Controller
[Documentation] Copy Controller values to Pccmock VM variables.
- BuiltIn.Set_Suite_Variable ${PCCMOCKVM_IP} ${CONTROLLER}
- BuiltIn.Set_Suite_Variable ${PCCMOCKVM_PASSWORD} ${CONTROLLER_PASSWORD}
- BuiltIn.Set_Suite_Variable ${PCCMOCKVM_PROMPT} ${CONTROLLER_PROMPT}
+ BuiltIn.Set_Suite_Variable ${PCCMOCKVM_IP} ${ODL_SYSTEM_IP}
+ BuiltIn.Set_Suite_Variable ${PCCMOCKVM_PASSWORD} ${ODL_SYSTEM_PASSWORD}
+ BuiltIn.Set_Suite_Variable ${PCCMOCKVM_PROMPT} ${ODL_SYSTEM_PROMPT}
BuiltIn.Set_Suite_Variable ${PCCMOCKVM_WORKSPACE} ${CONTROLLER_WORKSPACE}
BuiltIn.Set_Suite_Variable ${LOG_PATH} ${CONTROLLER_WORKSPACE}
Updater_From_Controller
[Documentation] Copy Controller values to Uprater VM variables.
- BuiltIn.Set_Suite_Variable ${UPDATERVM_IP} ${CONTROLLER}
- BuiltIn.Set_Suite_Variable ${UPDATERVM_PASSWORD} ${CONTROLLER_PASSWORD}
- BuiltIn.Set_Suite_Variable ${UPDATERVM_PROMPT} ${CONTROLLER_PROMPT}
+ BuiltIn.Set_Suite_Variable ${UPDATERVM_IP} ${ODL_SYSTEM_IP}
+ BuiltIn.Set_Suite_Variable ${UPDATERVM_PASSWORD} ${ODL_SYSTEM_PASSWORD}
+ BuiltIn.Set_Suite_Variable ${UPDATERVM_PROMPT} ${ODL_SYSTEM_PROMPT}
BuiltIn.Set_Suite_Variable ${UPDATERVM_WORKSPACE} ${CONTROLLER_WORKSPACE}
Disconnect
*** Settings ***
Documentation Test suite for capwap discover functionality
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Library ../../../libraries/Common.py
*** Test Cases ***
Get Discovered WTPs
[Documentation] Get the WTP Discoverd
- send discover ${CONTROLLER}
+ send discover ${ODL_SYSTEM_IP}
Wait Until Keyword Succeeds 10s 5s Run Test Get Discovered WTP
Get Specific WTP
[Documentation] Get the details of specific WTP.
- send discover ${CONTROLLER}
+ send discover ${ODL_SYSTEM_IP}
Wait Until Keyword Succeeds 10s 5s Run Test Get Specifc WTP
*** Keywords ***
${result} TO JSON ${resp.content}
${ac_Root} Get From Dictionary ${result} capwap-ac-root
@{wtp_discovered} Get From Dictionary ${ac_Root} discovered-wtps
- ${expected_ip_addr} get simulated wtpip ${CONTROLLER}
+ ${expected_ip_addr} get simulated wtpip ${ODL_SYSTEM_IP}
${wtp_ip_list} Create List ''
: FOR ${wtp} IN @{wtp_discovered}
\ ${wtp_ip} Get From Dictionary ${wtp} ipv4-addr
List Should Contain Value ${wtp_ip_list} ${expected_ip_addr}
Run Test Get Specifc WTP
- ${expected_ip_addr} get simulated wtpip ${CONTROLLER}
+ ${expected_ip_addr} get simulated wtpip ${ODL_SYSTEM_IP}
${DISC_SPECIFIC_WTP} catenate SEPARATOR= ${DISC_WTP_REST} discovered-wtps\/ ${expected_ip_addr} \/
Log ${DISC_SPECIFIC_WTP}
${resp} RequestsLibrary.Get Request session ${DISC_SPECIFIC_WTP}
Install a Feature odl-didm-mininet
Install a Feature odl-hp3800
Start Suite
- Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+ Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Library SSHLibrary
Library Collections
Library RequestsLibrary
-Resource ../../../variables/Variables.robot
+Resource ../../../variables/DIDM/Variables.robot
Variables ../../../variables/Variables.py
Resource ../../../libraries/Utils.robot
Resource ../../../libraries/MininetKeywords.robot
Verify Feature Is Installed odl-openflowplugin-all-li
${message}= Set Variable org.opendaylight.didm.ovs - 0.2.0.SNAPSHOT | Device-type Listener registered
Wait For Karaf Log ${message}
- Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+ Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Log Start device
${mininet_topo_opt}= Set Variable --topo linear,1 --switch ovsk,protocols=OpenFlow13
- ${mininet_conn_id}= Start Mininet Single Controller ${DEVICE_IP} ${CONTROLLER} ${mininet_topo_opt}
+ ${mininet_conn_id}= Start Mininet Single Controller ${TOOLS_SYSTEM_IP} ${ODL_SYSTEM_IP} ${mininet_topo_opt}
Wait Until Keyword Succeeds 11s 1s Check DIDM Registered With Device
Set Suite Variable ${mininet_conn_id}
Add Tenant to one node
[Documentation] Add one Tenant from JSON file
- Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+ Create Session session http://${ODL_SYSTEM_1_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
${jsonbody} Read JSON From File ${GBP_TENANT1_FILE}
Add Elements To URI From File ${GBP_TENANT1_API} ${GBP_TENANT1_FILE} headers=${HEADERS_YANG_JSON}
${resp} RequestsLibrary.Get Request session ${GBP_TENANT1_API}
Lists Should be Equal ${result} ${jsonbody}
Read Tenant from other node
- Create Session session http://${CONTROLLER1}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+ Create Session session http://${ODL_SYSTEM_2_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
${jsonbody} Read JSON From File ${GBP_TENANT1_FILE}
${resp} RequestsLibrary.Get Request session ${GBP_TENANT1_API}
Should Be Equal As Strings ${resp.status_code} 200
[Arguments] ${GBP} ${suite_dir} ${sw_index} ${timeout}=10s
ConnUtils.Connect and Login ${GBP} timeout=${timeout}
SSHLibrary.Put File ${suite_dir}/init_scripts/* ${VM_HOME_FOLDER}${/}${VM_SCRIPTS_FOLDER}/ mode=0755
- ${stdout} ${stderr} ${rc} Execute in VE python ${VM_HOME_FOLDER}${/}${VM_SCRIPTS_FOLDER}/infrastructure_launch.py ${CONTROLLER} ${sw_index} timeout=${timeout}
+ ${stdout} ${stderr} ${rc} Execute in VE python ${VM_HOME_FOLDER}${/}${VM_SCRIPTS_FOLDER}/infrastructure_launch.py ${ODL_SYSTEM_IP} ${sw_index} timeout=${timeout}
Should Be Equal As Numbers ${rc} 0
SSHLibrary.Close Connection
*** Settings ***
Documentation Test suite for GBP Tenants, Operates functions from Restconf APIs.
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Default Tags single-tenant setup single-tenant-setup
Library RequestsLibrary
*** Settings ***
Documentation Test suite for cleaning up / unregister infrastructure constructs like endpoints for demo-asymmetric-chain
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Default Tags single-tenant teardown single-tenant-teardown
Library RequestsLibrary
*** Settings ***
Documentation Test suite for GBP Tenants, Operates functions from Restconf APIs.
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Default Tags multi-tenant setup multi-tenant-setup
Library RequestsLibrary
*** Settings ***
Documentation Test suite for cleaning up / unregister infrastructure constructs like endpoints for demo-asymmetric-chain
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Default Tags multi-tenant teardown multi-tenant-teardown
Library RequestsLibrary
*** Settings ***
Documentation Test suite for setting up infrastructure for demo-asymmetric-chain
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_YANG_JSON}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_YANG_JSON}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Library OperatingSystem
*** Settings ***
Documentation Test suite for cleaning up / unregister infrastructure constructs like endpoints for demo-asymmetric-chain
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Library OperatingSystem
*** Settings ***
Documentation Test suite for setting up infrastructure for demo-symmetric-chain
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Library OperatingSystem
*** Settings ***
Documentation Test suite for cleaning up / unregister infrastructure constructs like endpoints for demo-symmetric-chain
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Library OperatingSystem
*** Settings ***
Documentation Test suite for Group Based Policy, Operates functions from Restconf APIs.
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Library SSHLibrary
Library Collections
*** Settings ***
Documentation Test suite for GBP Tenants, Operates functions from Restconf APIs.
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Library SSHLibrary
Library Collections
*** Settings ***
Documentation Test suite for GBP Tunnels, Operates functions from Restconf APIs.
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Library SSHLibrary
Library Collections
#!/bin/bash
-echo "Controller IP is ${CONTROLLER0}"
-echo "Mininet IP is ${MININET0}"
+echo "Controller IP is ${ODL_SYSTEM_IP}"
+echo "Mininet IP is ${TOOLS_SYSTEM_IP}"
echo "Distribution bundle URL is ${ACTUALBUNDLEURL}"
echo "Distribution bundle is ${BUNDLE}"
echo "Distribution bundle version is ${BUNDLEVERSION}"
${TOPO_TREE_DEPTH} Convert To Integer ${TOPO_TREE_DEPTH}
${TOPO_TREE_FANOUT} Convert To Integer ${TOPO_TREE_FANOUT}
${numnodes} Num Of Nodes ${TOPO_TREE_DEPTH} ${TOPO_TREE_FANOUT}
- Open Connection ${TOOLS_SYSTEM_IP} prompt=> timeout=${numnodes*3}
+ Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout=${numnodes*3}
Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
Write sudo ovs-vsctl set-manager ptcp:6644
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
Write sudo mn -c
- Read Until >
- Read Until >
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
+ Read Until ${DEFAULT_LINUX_PROMPT}
+ Read Until ${DEFAULT_LINUX_PROMPT}
Write ${start}
Read Until mininet>
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}
+ Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Wait Until Keyword Succeeds 10s 1s Verify LACP Tags Are Formed
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}
+ Create Session session http://${ODL_SYSTEM_IP}:${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
+ Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT}
+ Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
Write sudo ./m h2
Write sudo ifconfig ${port-id}
Write sudo ifconfig ${port-id} ${port-state}
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} #
+ ${group_output}= Run Command on Remote System ${TOOLS_SYSTEM_IP} sudo ovs-ofctl dump-groups s1 -O OpenFlow13 ${TOOLS_SYSTEM_USER} #
Log ${group_output}
Comment ${group_output} Read Until mininet>
${result}= Get Lines Containing String ${group_output} output:${port-id1}
*** 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
+ ${result}= Run Command On Remote System ${TOOLS_SYSTEM_IP} 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} #
+ ${result}= Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo ovs-ofctl dump-ports s1 -O OpenFlow13 ${TOOLS_SYSTEM_USER} #
Comment ${result} Read Until mininet>
${port1}= Get Lines Containing String ${result} 1:
Should Not Contain ${port1} rx pkts=0
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}
+ Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Wait Until Keyword Succeeds 15s 1s Verify LACP Tags Are Formed
*** Keywords ***
Start Suite
Log Start mininet
- ${mininet_session_id}= Open Connection ${MININET} prompt=${DEFAULT_LINUX_PROMPT} timeout=30s
+ ${mininet_session_id}= Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout=30s
Set Suite Variable ${mininet_session_id}
- Login With Public Key ${MININET_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
+ Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
Execute Command sudo ovs-vsctl set-manager ptcp:6633
Execute Command sudo rm -rf ${bond}
Put File ${CURDIR}/LACP_custom1.py
Put File ${CURDIR}/m
Put File ${CURDIR}/bonding.conf
Execute Command sudo cp bonding.conf ${bond}
- Execute Command sed -i -- 's/CONTROLLER/${CONTROLLER}/g' LACP_custom1.py
+ Execute Command sed -i -- 's/CONTROLLER/${ODL_SYSTEM_IP}/g' LACP_custom1.py
Write ${start}
Read Until mininet>
Switch Connection ${mininet_session_id}
Read
Write exit
- Execute Command sed -i -- 's/${CONTROLLER}/CONTROLLER/g' LACP_custom1.py
+ Execute Command sed -i -- 's/${ODL_SYSTEM_IP}/CONTROLLER/g' LACP_custom1.py
Execute Command sudo rm -rf ${bond}
Close Connection
Resource ${CURDIR}/../../../libraries/WaitForFailure.robot
*** Variables ***
-${MININET_PROMPT} ${DEFAULT_LINUX_PROMPT}
${ODL_LOG_LEVEL} DEFAULT
${TX_TYPE} {TX-CHAINING,SIMPLE-TX}
${OP_TYPE} {PUT,MERGE,DELETE}
[Documentation] Setup imported resources, SSH-login to mininet machine,
... create HTTP session, put Python tool to mininet machine.
SetupUtils.Setup_Utils_For_Setup_And_Teardown
- SSHLibrary.Set_Default_Configuration prompt=${MININET_PROMPT}
- SSHLibrary.Open_Connection ${MININET}
+ SSHLibrary.Set_Default_Configuration prompt=${TOOLS_SYSTEM_PROMPT}
+ SSHLibrary.Open_Connection ${TOOLS_SYSTEM_IP}
Utils.Flexible_Mininet_Login
SSHLibrary.Put_File ${CURDIR}/../../../../tools/mdsal_benchmark/${tool}
Start_Benchmark_Tool
[Documentation] Start the benchmark tool. Check that it has been running at least for ${tool_startup_timeout} period.
- ${command}= BuiltIn.Set_Variable python ${tool} --host ${CONTROLLER} --port ${RESTCONFPORT} --warmup ${WARMUPS} --runs ${RUNS} --total ${TOTAL_OPS} --inner ${INNER_OPS} --txtype ${TX_TYPE} --ops ${OPS_PER_TX} --optype ${OP_TYPE} --plot ${FILTER} --units ${UNITS} ${tool_args} &> ${tool_log_name}
+ ${command}= BuiltIn.Set_Variable python ${tool} --host ${ODL_SYSTEM_IP} --port ${RESTCONFPORT} --warmup ${WARMUPS} --runs ${RUNS} --total ${TOTAL_OPS} --inner ${INNER_OPS} --txtype ${TX_TYPE} --ops ${OPS_PER_TX} --optype ${OP_TYPE} --plot ${FILTER} --units ${UNITS} ${tool_args} &> ${tool_log_name}
BuiltIn.Log ${command}
${output}= SSHLibrary.Write ${command}
- ${status} ${message}= BuiltIn.Run Keyword And Ignore Error Write Until Expected Output ${EMPTY} ${MININET_PROMPT} ${tool_startup_timeout}
+ ${status} ${message}= BuiltIn.Run Keyword And Ignore Error Write Until Expected Output ${EMPTY} ${TOOLS_SYSTEM_PROMPT} ${tool_startup_timeout}
... 1s
BuiltIn.Log ${status}
BuiltIn.Log ${message}
*** Settings ***
Documentation Test suite to verify Restconf is OK
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Variables ../../../variables/Variables.py
[Return] ${data}
Create_ODL_Netconf_Connection
- [Arguments] ${host}=${CONTROLLER} ${port}=${ODL_NETCONF_MDSAL_PORT} ${user}=${ODL_NETCONF_USER} ${password}=${ODL_NETCONF_PASSWORD}
+ [Arguments] ${host}=${ODL_SYSTEM_IP} ${port}=${ODL_NETCONF_MDSAL_PORT} ${user}=${ODL_NETCONF_USER} ${password}=${ODL_NETCONF_PASSWORD}
[Documentation] Open a netconf connecion to the given machine.
# The "-s netconf" flag (see the "SSHLibrary.Write" line below) is not
# supported by SSHLibrary, therefore we need to use this elaborate and
Setup_Everything
[Documentation] Setup resources and create session for Restconf checking.
SetupUtils.Setup_Utils_For_Setup_And_Teardown
- RequestsLibrary.Create_Session config http://${CONTROLLER}:${RESTCONFPORT}${CONFIG_API} auth=${AUTH}
+ RequestsLibrary.Create_Session config http://${ODL_SYSTEM_IP}:${RESTCONFPORT}${CONFIG_API} auth=${AUTH}
Teardown_Everything
[Documentation] Close the Netconf connection and destroy all sessions in the requests library.
${output_log} = SSHLibrary.Execute_Command python -c "help('modules')"
BuiltIn.Log ${output_log}
Should Contain ${output_log} websocket
- RequestsLibrary.Create Session restconf http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH}
- BuiltIn.Log http://${CONTROLLER}:${RESTCONFPORT}
+ RequestsLibrary.Create Session restconf http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH}
+ BuiltIn.Log http://${ODL_SYSTEM_IP}:${RESTCONFPORT}
KarafKeywords.Execute_Controller_Karaf_Command_On_Background log:set ${CONTROLLER_LOG_LEVEL}
Teardown_Everything
KarafKeywords.Open_Controller_Karaf_Console_On_Background
KarafKeywords.Log_Message_To_Controller_Karaf Starting Netconf readiness test suite
BuiltIn.Run_Keyword_If ${DEBUG_LOGGING_FOR_EVERYTHING} KarafKeywords.Execute_Controller_Karaf_Command_On_Background log:set DEBUG
- RequestsLibrary.Create_Session ses http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH}
+ RequestsLibrary.Create_Session ses http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH}
NetconfKeywords.Setup_Netconf_Keywords
Teardown_Everything
*** Settings ***
Documentation Test suite to verify Restconf is OK for NetIDE.
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Variables ../../../variables/Variables.py
... a larger number of failed connections will be used and a small margin of error will
... determine if the test is a PASS or FAIL
Log Environment Details
- ${controller_pid}= Get Process ID Based On Regex On Remote System ${ODL_SYSTEM_IP} java.*distribution.*karaf ${CONTROLLER_USER}
+ ${controller_pid}= Get Process ID Based On Regex On Remote System ${ODL_SYSTEM_IP} java.*distribution.*karaf ${ODL_SYSTEM_USER}
Should Match Regexp ${controller_pid} [0-9]+ PID was not discovered
- ${starting_thread_count}= Get Process Thread Count On Remote System ${ODL_SYSTEM_IP} ${controller_pid} ${CONTROLLER_USER}
+ ${starting_thread_count}= Get Process Thread Count On Remote System ${ODL_SYSTEM_IP} ${controller_pid} ${ODL_SYSTEM_USER}
Repeat Keyword ${number_ofconnections_to_fail} Start Process nc -w 1 ${ODL_SYSTEM_IP}
... ${openflow_port}
Run pkill -f 'nc -w'
Log Environment Details
- ${ending_thread_count}= Get Process Thread Count On Remote System ${ODL_SYSTEM_IP} ${controller_pid} ${CONTROLLER_USER}
+ ${ending_thread_count}= Get Process Thread Count On Remote System ${ODL_SYSTEM_IP} ${controller_pid} ${ODL_SYSTEM_USER}
Log Environment Details
Log starting count: ${starting_thread_count}\nending count: ${ending_thread_count}
${acceptable_thread_count}= Evaluate ${starting_thread_count} + (${number_of_connections_to_fail} * ${margin_of_error})
Log Environment Details
[Documentation] Will display relevant details of the test environement to help aid debugging efforts if
... needed in the future.
- ${output}= Get Process ID Based On Regex On Remote System ${ODL_SYSTEM_IP} java.*distribution.*karaf ${CONTROLLER_USER}
+ ${output}= Get Process ID Based On Regex On Remote System ${ODL_SYSTEM_IP} java.*distribution.*karaf ${ODL_SYSTEM_USER}
Log ${output}
- ${output}= Run Command On Remote System ${ODL_SYSTEM_IP} netstat -na | grep 6633 ${CONTROLLER_USER}
+ ${output}= Run Command On Remote System ${ODL_SYSTEM_IP} netstat -na | grep 6633 ${ODL_SYSTEM_USER}
Log ${output}
${TOPO_TREE_DEPTH} Convert To Integer ${TOPO_TREE_DEPTH}
${TOPO_TREE_FANOUT} Convert To Integer ${TOPO_TREE_FANOUT}
${numnodes} Num Of Nodes ${TOPO_TREE_DEPTH} ${TOPO_TREE_FANOUT}
- Open Connection ${TOOLS_SYSTEM_IP} prompt=> timeout=${numnodes*2}
+ Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout=${numnodes*2}
Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
Write sudo ovs-vsctl set-manager ptcp:6644
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
Write sudo mn -c
- Read Until >
- Read Until >
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
+ Read Until ${DEFAULT_LINUX_PROMPT}
+ Read Until ${DEFAULT_LINUX_PROMPT}
Write ${start}
Read Until mininet>
Log Stop mininet
Read
Write exit
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
Close Connection
${TOPO_TREE_DEPTH} Convert To Integer ${TOPO_TREE_DEPTH}
${TOPO_TREE_FANOUT} Convert To Integer ${TOPO_TREE_FANOUT}
${numnodes} Num Of Nodes ${TOPO_TREE_DEPTH} ${TOPO_TREE_FANOUT}
- Open Connection ${TOOLS_SYSTEM_IP} prompt=> timeout=${numnodes*3}
+ Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout=${numnodes*3}
Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
Write sudo ovs-vsctl set-manager ptcp:6644
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
Write sudo mn -c
- Read Until >
- Read Until >
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
+ Read Until ${DEFAULT_LINUX_PROMPT}
+ Read Until ${DEFAULT_LINUX_PROMPT}
Write ${start}
Read Until mininet>
Log Stop mininet
Read
Write exit
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
Close Connection
Start Suite
[Documentation] Starts mininet with requested number of switches
Log Start the test on the base edition
- ${mininet_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} prompt=> timeout=1800
+ ${mininet_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout=1800
Set Suite Variable ${mininet_conn_id}
Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
Put File ${CURDIR}/../../../libraries/DynamicMininet.py DynamicMininet.py
[Documentation] Basic setup/cleanup work that can be done safely before any system
... is run.
Log Start the test on the base edition
- ${mininet_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} prompt=> timeout=600s
+ ${mininet_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout=600s
Set Suite Variable ${mininet_conn_id}
Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
Write sudo ovs-vsctl set-manager ptcp:6644
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
Write sudo mn -c
- Read Until >
- Read Until >
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
+ Read Until ${DEFAULT_LINUX_PROMPT}
+ Read Until ${DEFAULT_LINUX_PROMPT}
Write ${start}
Read Until mininet>
- Sleep 6
Stop Suite
[Documentation] Cleanup/Shutdown work that should be done at the completion of all
Switch Connection ${mininet_conn_id}
Read
Write exit
- Read Until >
+ Read Until ${DEFAULT_LINUX_PROMPT}
Close Connection
Start Http Session
*** Keywords ***
Start Suite
Log Start the test on the base edition
- ${mininet_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} prompt=>
+ ${mininet_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT}
Set Suite Variable ${mininet_conn_id}
Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/id_rsa any
Put File ${CURDIR}/../../../libraries/DynamicMininet.py .
Check OpenDaylight Networks
[Documentation] Checking OpenDaylight Neutron API for Known Networks
[Tags] Network Neutron OpenDaylight
- Create Session ODLSession http://${CONTROLLER}:${PORT} headers=${HEADERS} auth=${AUTH}
+ Create Session ODLSession http://${ODL_SYSTEM_IP}:${PORT} headers=${HEADERS} auth=${AUTH}
${resp} get ODLSession ${ODLREST}
Should be Equal As Strings ${resp.status_code} 200
${ODLResult} To Json ${resp.content}
Check OpenDaylight subnets
[Documentation] Checking OpenDaylight Neutron API for Known Subnets
[Tags] Subnets Neutron OpenDaylight
- Create Session ODLSession http://${CONTROLLER}:${PORT} headers=${HEADERS} auth=${AUTH}
+ Create Session ODLSession http://${ODL_SYSTEM_IP}:${PORT} headers=${HEADERS} auth=${AUTH}
${resp} get ODLSession ${ODLREST}
Should be Equal As Strings ${resp.status_code} 200
${ODLResult} To Json ${resp.content}
Check OpenDaylight ports
[Documentation] Checking OpenDaylight Neutron API for Known Ports
[Tags] Ports Neutron OpenDaylight
- Create Session ODLSession http://${CONTROLLER}:${PORT} headers=${HEADERS} auth=${AUTH}
+ Create Session ODLSession http://${ODL_SYSTEM_IP}:${PORT} headers=${HEADERS} auth=${AUTH}
${resp} get ODLSession ${ODLREST}
Should be Equal As Strings ${resp.status_code} 200
${ODLResult} To Json ${resp.content}
*** Settings ***
Documentation Test suite connecting ODL to Mininet
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Test Teardown Collect OVSDB Debugs
Library SSHLibrary
Make the OVS instance to listen for connection
[Documentation] Connect OVS to ODL
[Tags] OVSDB netvirt
- Clean Up Ovs ${MININET}
- Run Command On Remote System ${MININET} sudo ovs-vsctl set-manager tcp:${CONTROLLER}:${OVSDB_PORT}
- ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
- ${pingresult} Run Command On Remote System ${MININET} ping ${CONTROLLER} -c 4
+ Clean Up Ovs ${TOOLS_SYSTEM_IP}
+ Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo ovs-vsctl set-manager tcp:${ODL_SYSTEM_IP}:${OVSDB_PORT}
+ ${output} Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo ovs-vsctl show
+ ${pingresult} Run Command On Remote System ${TOOLS_SYSTEM_IP} ping ${ODL_SYSTEM_IP} -c 4
Should Not Contain ${pingresult} ${PING_NOT_CONTAIN}
Wait Until Keyword Succeeds 8s 2s Check For Elements At URI ${OPERATIONAL_TOPO_API} ${node_list}
Get manager connection
[Documentation] This will verify if the OVS manager is connected
[Tags] OVSDB netvirt
- ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
+ ${output} Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo ovs-vsctl show
${lines}= Get Lines Containing String ${output} is_connected
${manager}= Get Line ${lines} 0
Should Contain ${manager} true
Get controller connection
[Documentation] This will verify if the OpenFlow controller is connected on all bridges
[Tags] OVSDB netvirt
- ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
+ ${output} Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo ovs-vsctl show
${lines}= Get Lines Containing String ${output} is_connected
${list}= Split String ${lines} \n
Remove From List ${list} 0
Get bridge setup
[Documentation] This request is verifying that the br-int bridge has been created
[Tags] OVSDB netvirt
- ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
- Should Contain ${output} Controller "tcp:${CONTROLLER}:${OF_PORT}"
+ ${output} Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo ovs-vsctl show
+ Should Contain ${output} Controller "tcp:${ODL_SYSTEM_IP}:${OF_PORT}"
Should Contain ${output} Bridge br-int
Get port setup
[Documentation] This will check the port br-int has been created
[Tags] OVSDB netvirt
- ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
+ ${output} Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo ovs-vsctl show
Should Contain ${output} Port br-int
Get interface setup
[Documentation] This verify the interface br-int has been created
[Tags] OVSDB netvirt
- ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
+ ${output} Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo ovs-vsctl show
Should Contain ${output} Interface br-int
Get the bridge flows
[Documentation] This request fetch the OF13 flow tables to verify the flows are correctly added
[Tags] OVSDB netvirt
- ${output} Run Command On Remote System ${MININET} sudo ovs-ofctl -O Openflow13 dump-flows br-int
+ ${output} Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo ovs-ofctl -O Openflow13 dump-flows br-int
Should Contain ${output} ${FLOWS_TABLE_20}
Should Contain ${output} ${FLOW_CONTROLLER}
Should Contain ${output} ${FLOWS_TABLE_30}
*** Settings ***
Documentation Checking Network created in OVSDB are pushed to OpenDaylight
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Test Teardown Collect OVSDB Debugs
Library SSHLibrary
Add variables to controller custom.properties
[Documentation] Add variables to custom.properties
[Tags] Enable l3 forwarding
- Run Command On Remote System ${CONTROLLER} echo 'ovsdb.l3.fwd.enabled=yes' >> ${WORKSPACE}/${BUNDLEFOLDER}/etc/custom.properties
- Run Command On Remote System ${CONTROLLER} echo 'ovsdb.l3gateway.mac=00:00:5E:00:02:01' >> ${WORKSPACE}/${BUNDLEFOLDER}/etc/custom.properties
- ${controller_pid_1}= Get Process ID Based On Regex On Remote System ${CONTROLLER} java.*distribution.*karaf
- Run Command On Remote System ${CONTROLLER} kill -SIGTERM ${controller_pid_1}
- Run Command On Remote System ${CONTROLLER} ${WORKSPACE}/${BUNDLEFOLDER}/bin/start
- ${controller_pid_2}= Get Process ID Based On Regex On Remote System ${CONTROLLER} java.*distribution.*karaf
+ Run Command On Remote System ${ODL_SYSTEM_IP} echo 'ovsdb.l3.fwd.enabled=yes' >> ${WORKSPACE}/${BUNDLEFOLDER}/etc/custom.properties
+ Run Command On Remote System ${ODL_SYSTEM_IP} echo 'ovsdb.l3gateway.mac=00:00:5E:00:02:01' >> ${WORKSPACE}/${BUNDLEFOLDER}/etc/custom.properties
+ ${controller_pid_1}= Get Process ID Based On Regex On Remote System ${ODL_SYSTEM_IP} java.*distribution.*karaf
+ Run Command On Remote System ${ODL_SYSTEM_IP} kill -SIGTERM ${controller_pid_1}
+ Run Command On Remote System ${ODL_SYSTEM_IP} ${WORKSPACE}/${BUNDLEFOLDER}/bin/start
+ ${controller_pid_2}= Get Process ID Based On Regex On Remote System ${ODL_SYSTEM_IP} java.*distribution.*karaf
Should Not be Equal As Numbers ${controller_pid_1} ${controller_pid_2}
Ensure controller is running
[Documentation] Create Port DHCP
[Tags] OpenStack Call Flow
${Data} OperatingSystem.Get File ${OVSDB_CONFIG_DIR}/create_port_dhcp.json
- ${Data} Replace String ${Data} {BIND_HOST_ID} ${CONTROLLER}
+ ${Data} Replace String ${Data} {BIND_HOST_ID} ${ODL_SYSTEM_IP}
${Data} Replace String ${Data} {subnetId} ${TNT1_SUBNET1_ID}
${Data} Replace String ${Data} {dhcpDeviceId} ${TNT1_NET1_DHCP_DEVICE_ID}
${Data} Replace String ${Data} {netId} ${TNT1_NET1_ID}
[Documentation] Update Port DHCP
[Tags] OpenStack Call Flow
${Data} OperatingSystem.Get File ${OVSDB_CONFIG_DIR}/update_port_dhcp.json
- ${Data} Replace String ${Data} {BIND_HOST_ID} ${CONTROLLER}
+ ${Data} Replace String ${Data} {BIND_HOST_ID} ${ODL_SYSTEM_IP}
${Data} Replace String ${Data} {dhcpDeviceId} ${TNT1_NET1_DHCP_DEVICE_ID}
Log ${Data}
${resp} RequestsLibrary.Put Request session ${ODLREST}/ports/${TNT1_NET1_DHCP_PORT_ID} ${Data}
[Documentation] Create Port VM
[Tags] OpenStack Call Flow
${Data} OperatingSystem.Get File ${OVSDB_CONFIG_DIR}/create_port_vm.json
- ${Data} Replace String ${Data} {BIND_HOST_ID} ${CONTROLLER}
+ ${Data} Replace String ${Data} {BIND_HOST_ID} ${ODL_SYSTEM_IP}
${Data} Replace String ${Data} {tntId} ${TNT1_ID}
${Data} Replace String ${Data} {netId} ${TNT1_NET1_ID}
${Data} Replace String ${Data} {subnetId} ${TNT1_SUBNET1_ID}
Start Mininet Multiple Connections
[Documentation] Start mininet with connection to all cluster instances.
- ${mininet_conn_id} Add Multiple Managers to OVS ${MININET} ${original_cluster_list}
+ ${mininet_conn_id} Add Multiple Managers to OVS ${TOOLS_SYSTEM_IP} ${original_cluster_list}
Set Suite Variable ${mininet_conn_id}
Log ${mininet_conn_id}
${device_id} Find Device Id ${device2_ip}
Issue Command On Karaf Console networkdevice:set-location ${device_id} ${location2}
Issue Command On Karaf Console networkdevice:set-friendly-name ${device_id} ${device2_name}
- Stop One Or More Controllers ${CONTROLLER}
- Wait Until Keyword Succeeds 60s 3s Controller Down Check ${CONTROLLER}
- Start One Or More Controllers ${CONTROLLER}
- UtilLibrary.Wait For Controller Up ${CONTROLLER} ${RESTCONFPORT}
+ Stop One Or More Controllers ${ODL_SYSTEM_IP}
+ Wait Until Keyword Succeeds 60s 3s Controller Down Check ${ODL_SYSTEM_IP}
+ Start One Or More Controllers ${ODL_SYSTEM_IP}
+ UtilLibrary.Wait For Controller Up ${ODL_SYSTEM_IP} ${RESTCONFPORT}
${output}= Issue Command On Karaf Console user:get-enabled
${string}= Extract String To Validate ${output} User{username=Username{value= 0
Should Match ${string} ${username}
*** Settings ***
Documentation Test suite to verify Restconf is OK
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Variables ../../../variables/Variables.py
Resource ../../../libraries/Utils.robot
*** Variables ***
-${REST_CONTEXT} /restconf/modules
*** Test Cases ***
Get Controller Modules
[Documentation] Get the controller modules via Restconf
- ${resp} RequestsLibrary.Get Request session ${REST_CONTEXT}
+ ${resp} RequestsLibrary.Get Request session ${MODULES_API}
Log ${resp.content}
Should Be Equal As Strings ${resp.status_code} 200
Should Contain ${resp.content} ietf-restconf
*** Settings ***
Documentation Test suite to verify Restconf is OK
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Variables ../../../variables/Variables.py
*** Variables ***
-${REST_CONTEXT} /restconf/modules
*** Test Cases ***
Get Controller Modules
[Documentation] Get the controller modules via Restconf
- ${resp} RequestsLibrary.Get Request session ${REST_CONTEXT}
+ ${resp} RequestsLibrary.Get Request session ${MODULES_API}
Log ${resp.content}
Should Be Equal As Strings ${resp.status_code} 200
Should Contain ${resp.content} ietf-restconf
*** Test Cases ***
Verification of TSDR Cassandra Feature Installation
[Documentation] Install and Verify the TSDR Cassandra Features
- COMMENT Install a Feature odl-tsdr-cassandra-all ${CONTROLLER} ${KARAF_SHELL_PORT} 60
+ COMMENT Install a Feature odl-tsdr-cassandra-all ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 60
Verify Feature Is Installed odl-tsdr-cassandra
COMMENT Verify Feature Is Installed odl-tsdr-cassandra-persistence
Verify Feature Is Installed odl-tsdr-openflow-statistics-collector
*** Test Cases ***
Verification of TSDR H2 Feature Installation
[Documentation] Install and Verify the TSDR H2 Datastore and JDBC
- Install a Feature jdbc ${CONTROLLER} ${KARAF_SHELL_PORT} 60
+ Install a Feature jdbc ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 60
Verify Feature Is Installed jdbc
- COMMENT Install a Feature odl-tsdr-all ${CONTROLLER} ${KARAF_SHELL_PORT} 60
+ COMMENT Install a Feature odl-tsdr-all ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 60
Verify Feature Is Installed odl-tsdr-all
Verify Feature Is Installed odl-tsdr-H2-persistence
Verify Feature Is Installed odl-tsdr-core
[Documentation] Verify the InterfaceMetrics(PortStats),attributes using ${TSDR_PORTSTATS}
: FOR ${list} IN @{INTERFACE_METRICS}
\ ${tsdr_cmd}= Concatenate the String ${TSDR_PORTSTATS} | grep ${list} | head
- \ ${output}= Issue Command On Karaf Console ${tsdr_cmd} ${CONTROLLER} ${KARAF_SHELL_PORT} 30
+ \ ${output}= Issue Command On Karaf Console ${tsdr_cmd} ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 30
\ Should Contain ${output} ${list}
Verify PortStats-Attributes on H2 Datastore using JDBC Client
Verification of TSDR FlowMetrics
[Documentation] Verify the TSDR FlowStats
Wait Until Keyword Succeeds 60s 1s Verify the Metric is Collected? ${TSDR_FLOWSTATS} PacketCount
- ${output}= Issue Command On Karaf Console ${TSDR_FLOWSTATS} ${CONTROLLER} ${KARAF_SHELL_PORT} 30
+ ${output}= Issue Command On Karaf Console ${TSDR_FLOWSTATS} ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 30
: FOR ${list} IN @{FLOW_METRICS}
\ Should Contain ${output} ${list}
Verification of TSDR FlowTableStats
[Documentation] Verify the TSDR FlowiTableStats
Wait Until Keyword Succeeds 60s 1s Verify the Metric is Collected? ${TSDR_FLOWTABLE_STATS}| grep ActiveFlow FLOWTABLESTATS
- ${output}= Issue Command On Karaf Console ${TSDR_FLOWTABLE_STATS}| grep openflow:1 | head ${CONTROLLER} ${KARAF_SHELL_PORT} 180
+ ${output}= Issue Command On Karaf Console ${TSDR_FLOWTABLE_STATS}| grep openflow:1 | head ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 180
: FOR ${list} IN @{FLOWTABLE_METRICS}
\ Should Contain ${output} ${list}
Verify the Queue Stats attributes exist thru Karaf console
[Documentation] Verify the QueueMetrics attributes exist on Karaf Console
Wait Until Keyword Succeeds 60s 1s Verify the Metric is Collected? ${TSDR_QUEUE_STATS} Transmitted
- ${output}= Issue Command On Karaf Console ${TSDR_QUEUE_STATS} ${CONTROLLER} ${KARAF_SHELL_PORT} 30
+ ${output}= Issue Command On Karaf Console ${TSDR_QUEUE_STATS} ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 30
: FOR ${list} IN @{QUEUE_METRICS}
\ Should Contain ${output} ${list}
Verify tsdr:purgeall command
[Documentation] Verify the tsdr:purgeall command
- Issue Command On Karaf Console tsdr:purgeall ${CONTROLLER} ${KARAF_SHELL_PORT}
+ Issue Command On Karaf Console tsdr:purgeall ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT}
: FOR ${list} IN @{CMD_LIST}
- \ ${out}= Issue Command On Karaf Console tsdr:list ${list} ${CONTROLLER} ${KARAF_SHELL_PORT}
+ \ ${out}= Issue Command On Karaf Console tsdr:list ${list} ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT}
\ Should Contain ${out} no data of this category
: FOR ${list} IN @{QUEUE_METRICS}
\ ${out}= Query Metrics on H2 Datastore QUEUESTATS ${list}
Verify the FlowGroup Stats attributes exist thru Karaf console
[Documentation] Verify the FlowGroupStats attributes exist on Karaf Console
Wait Until Keyword Succeeds 120s 1s Verify the Metric is Collected? ${TSDR_FLOWGROUPSTATS} ByteCount
- ${output}= Issue Command On Karaf Console ${TSDR_FLOWGROUPSTATS} ${CONTROLLER} ${KARAF_SHELL_PORT} 30
+ ${output}= Issue Command On Karaf Console ${TSDR_FLOWGROUPSTATS} ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 30
: FOR ${list} IN @{FLOWGROUP_METRICS}
\ Should Contain ${output} ${list}
Verification of FlowGroupStats-ByteCount on Karaf Console
[Documentation] Verify the FlowGroupStats has been updated thru tsdr:list command on karaf console
${tsdr_cmd}= Concatenate the String ${TSDR_FLOWGROUPSTATS} | grep ByteCount | head
- ${output}= Issue Command On Karaf Console ${tsdr_cmd} ${CONTROLLER} ${KARAF_SHELL_PORT} 90
+ ${output}= Issue Command On Karaf Console ${tsdr_cmd} ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 90
Should Contain ${output} ByteCount
Should Contain ${output} FLOWGROUPSTATS
Should not Contain ${output} null
Configuration of FlowGroup on Switch
[Documentation] FlowGroup configuration on CPqD
- Run Command On Remote System ${MININET} sudo dpctl unix:/tmp/s1 group-mod cmd=add,group=1,type=all
- Run Command On Remote System ${MININET} sudo dpctl unix:/tmp/s1 flow-mod table=0,cmd=add eth_type=0x800,eth_src=00:01:02:03:04:05 apply:group=1
- Run Command On Remote System ${MININET} sudo dpctl unix:/tmp/s1 ping 10
- Run Command On Remote System ${MININET} sudo dpctl unix:/tmp/s2 ping 10
+ Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo dpctl unix:/tmp/s1 group-mod cmd=add,group=1,type=all
+ Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo dpctl unix:/tmp/s1 flow-mod table=0,cmd=add eth_type=0x800,eth_src=00:01:02:03:04:05 apply:group=1
+ Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo dpctl unix:/tmp/s1 ping 10
+ Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo dpctl unix:/tmp/s2 ping 10
Verify the FlowMeter Stats attributes exist thru Karaf console
[Documentation] Verify the FlowMeterStats attributes exist on Karaf Console
Wait Until Keyword Succeeds 120s 1s Verify the Metric is Collected? ${TSDR_FLOWMETERSTATS} ByteInCount
- ${output}= Issue Command On Karaf Console ${TSDR_FLOWMETERSTATS} ${CONTROLLER} ${KARAF_SHELL_PORT} 30
+ ${output}= Issue Command On Karaf Console ${TSDR_FLOWMETERSTATS} ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 30
: FOR ${list} IN @{FLOWMETER_METRICS}
\ Should Contain ${output} ${list}
Verification of FlowMeterStats-ByteInCount on Karaf Console
[Documentation] Verify the FlowMeterStats has been updated thru tsdr:list command on karaf console
${tsdr_cmd}= Concatenate the String ${TSDR_FLOWMETERSTATS} | grep ByteInCount | head
- ${output}= Issue Command On Karaf Console ${tsdr_cmd} ${CONTROLLER} ${KARAF_SHELL_PORT} 90
+ ${output}= Issue Command On Karaf Console ${tsdr_cmd} ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 90
Should Contain ${output} ByteInCount
Should Contain ${output} FLOWMETERSTATS
Should not Contain ${output} null
Verification TSDR Command shouldnot exist in help
[Documentation] Verify the TSDR List command on help
- ${output}= Issue Command On Karaf Console tsdr\t ${CONTROLLER} ${KARAF_SHELL_PORT}
+ ${output}= Issue Command On Karaf Console tsdr\t ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT}
Should not Contain ${output} tsdr:list
*** Keyword ***
Configuration of FlowMeter on Switch
[Documentation] FlowMeter configuration on CPqD
- Run Command On Remote System ${MININET} sudo dpctl unix:/tmp/s1 meter-mod cmd=add,flags=1,meter=1 drop:rate=100
- Run Command On Remote System ${MININET} sudo dpctl unix:/tmp/s1 flow-mod table=0,cmd=add in_port=1 meter:1 apply:output=2
- Run Command On Remote System ${MININET} sudo dpctl unix:/tmp/s1 ping 10
- Run Command On Remote System ${MININET} sudo dpctl unix:/tmp/s2 ping 10
+ Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo dpctl unix:/tmp/s1 meter-mod cmd=add,flags=1,meter=1 drop:rate=100
+ Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo dpctl unix:/tmp/s1 flow-mod table=0,cmd=add in_port=1 meter:1 apply:output=2
+ Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo dpctl unix:/tmp/s1 ping 10
+ Run Command On Remote System ${TOOLS_SYSTEM_IP} sudo dpctl unix:/tmp/s2 ping 10
*** Test Cases ***
Verification of TSDR HSQLDB Feature Installation
[Documentation] Install and Verify the TSDR Cassandra Syslog Features
- COMMENT Install a Feature odl-tsdr-hsqldb-all ${CONTROLLER} ${KARAF_SHELL_PORT} 60
- COMMENT Install a Feature odl-tsdr-syslog-collector ${CONTROLLER} ${KARAF_SHELL_PORT} 60
+ COMMENT Install a Feature odl-tsdr-hsqldb-all ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 60
+ COMMENT Install a Feature odl-tsdr-syslog-collector ${ODL_SYSTEM_IP} ${KARAF_SHELL_PORT} 60
Wait Until Keyword Succeeds 24x 10 sec Check Karaf Log Has Messages tsdr.syslog
Verify Feature Is Installed odl-tsdr-hsqldb
Verify Feature Is Installed odl-tsdr-syslog-collector
*** Settings ***
Documentation Test suite to verify Restconf is OK
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Library ../../../libraries/Common.py
*** Settings ***
Documentation Test suite for usc channel functionality
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Library ../../../libraries/Common.py
Resource ../../../libraries/Utils.robot
*** Variables ***
-${REST_CONTEXT} /restconf/modules
*** Test Cases ***
Get Controller Modules
[Documentation] Get the controller modules via Restconf
- ${resp} RequestsLibrary.Get session ${REST_CONTEXT}
+ ${resp} RequestsLibrary.Get session ${MODULES_API}
Log ${resp.content}
Should Be Equal As Strings ${resp.status_code} 200
Should Contain ${resp.content} ietf-restconf
*** Settings ***
Documentation Test suite to verify Restconf is OK
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS_XML}
Suite Teardown Delete All Sessions
Library RequestsLibrary
Variables ../../../variables/Variables.py
Resource ../../../libraries/Utils.robot
*** Variables ***
-${REST_CONTEXT} /restconf/modules
*** Test Cases ***
Get Controller Modules
[Documentation] Get the controller modules via Restconf
- ${resp} RequestsLibrary.Get Request session ${REST_CONTEXT}
+ ${resp} RequestsLibrary.Get Request session ${MODULES_API}
Log ${resp.content}
Should Be Equal As Strings ${resp.status_code} 200
Should Contain ${resp.content} ietf-restconf
*** Settings ***
Documentation Test Suite for vpn instance
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
Library OperatingSystem
Library String
*** Settings ***
Documentation Test Suite for vpn instance
-Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
+Suite Setup Create Session session http://${ODL_SYSTEM_IP}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
Suite Teardown Delete All Sessions
-Variables ../../variables/vpnservice/configureSwitches.py ${MININET} ${MININET1}
+Variables ../../variables/vpnservice/configureSwitches.py ${TOOLS_SYSTEM_IP} ${TOOLS_SYSTEM_2_IP}
Library SSHLibrary
Variables ../../variables/Variables.py
Resource ../../libraries/Utils.robot
Resource ../../libraries/Utils.robot
*** Variables ***
-${start1} sudo mn \ --controller=remote,ip=${CONTROLLER} --custom custom.py --topo Switch1 --switch ovsk,protocols=OpenFlow13
-${start2} sudo mn \ --controller=remote,ip=${CONTROLLER} --custom custom.py --topo Switch2 --switch ovsk,protocols=OpenFlow13
+${start1} sudo mn \ --controller=remote,ip=${ODL_SYSTEM_IP} --custom custom.py --topo Switch1 --switch ovsk,protocols=OpenFlow13
+${start2} sudo mn \ --controller=remote,ip=${ODL_SYSTEM_IP} --custom custom.py --topo Switch2 --switch ovsk,protocols=OpenFlow13
*** Keywords ***
Start Suite
[Documentation] Test suit for vpn service using mininet OF13 and OVS 2.3.1
Log Start the tests
Clean Mininet System
- ${mininet1_conn_id_1}= Open Connection ${MININET} prompt=${DEFAULT_LINUX_PROMPT} timeout=30s
+ ${mininet1_conn_id_1}= Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout=30s
Set Global Variable ${mininet1_conn_id_1}
- Login With Public Key ${MININET_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
+ Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
Execute Command sudo ovs-vsctl set-manager ptcp:6644
Put File ${CURDIR}/custom.py
Write ${start1}
Read Until mininet>
- ${mininet1_conn_id_2}= Open Connection ${MININET} prompt=${DEFAULT_LINUX_PROMPT} timeout= 30s
+ ${mininet1_conn_id_2}= Open Connection ${TOOLS_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout= 30s
Set Global Variable ${mininet1_conn_id_2}
- Login With Public Key ${MININET_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
- Execute Command sudo ovs-vsctl add-port s1 s1-gre1 -- set interface s1-gre1 type=gre options:remote_ip=${MININET1} options:local_ip=${MININET}
+ Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
+ Execute Command sudo ovs-vsctl add-port s1 s1-gre1 -- set interface s1-gre1 type=gre options:remote_ip=${TOOLS_SYSTEM_2_IP} options:local_ip=${TOOLS_SYSTEM_IP}
${output} Execute Command sudo ovs-vsctl show
Log ${output}
Execute Command sudo ovs-ofctl add-flow s1 -O OpenFlow13 arp,actions=FLOOD
- ${mininet2_conn_id_1}= Open Connection ${MININET1} prompt=${DEFAULT_LINUX_PROMPT} timeout=30s
+ ${mininet2_conn_id_1}= Open Connection ${TOOLS_SYSTEM_2_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout=30s
Set Global Variable ${mininet2_conn_id_1}
- Login With Public Key ${MININET_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
+ Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
Execute Command sudo ovs-vsctl set-manager ptcp:6644
Put File ${CURDIR}/custom.py
Write ${start2}
Read Until mininet>
- ${mininet2_conn_id_2}= Open Connection ${MININET1} prompt=${DEFAULT_LINUX_PROMPT} timeout= 30s
+ ${mininet2_conn_id_2}= Open Connection ${TOOLS_SYSTEM_2_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout= 30s
Set Global Variable ${mininet2_conn_id_2}
- Login With Public Key ${MININET_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
- Execute Command sudo ovs-vsctl add-port s2 s2-gre1 -- set interface s2-gre1 type=gre options:remote_ip=${MININET} options:local_ip=${MININET1}
+ Login With Public Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any
+ Execute Command sudo ovs-vsctl add-port s2 s2-gre1 -- set interface s2-gre1 type=gre options:remote_ip=${TOOLS_SYSTEM_IP} options:local_ip=${TOOLS_SYSTEM_2_IP}
${output} Execute Command sudo ovs-vsctl show
Log ${output}
Execute Command sudo ovs-ofctl add-flow s2 -O OpenFlow13 arp,actions=FLOOD
--- /dev/null
+*** Variables ***
+# DIDM suite variables
+${DEVICE_TYPE} mininet
+${DEVICE_DESCRIPTION} None
+${DEVICE_HW_INFO} Open vSwitch
+${DEVICE_SW_INFO} 2.0.0
+${DEVICE_MANUFACTURE} Nicira, Inc.
+${DEVICE_SERIAL_NUMBER} None
# Deprecated old variables, to be removed once all tests that need them are
# updated to use the new names.
CONTROLLER = ODL_SYSTEM_IP
-CONTROLLERS = ['CONTROLLER', 'CONTROLLER1', 'CONTROLLER2']
+CONTROLLERS = ['ODL_SYSTEM_1_IP', 'ODL_SYSTEM_2_IP', 'ODL_SYSTEM_3_IP']
CONTROLLER_PASSWORD = ODL_SYSTEM_PASSWORD
CONTROLLER_PROMPT = ODL_SYSTEM_PROMPT
-MININET = TOOLS_SYSTEM_IP
-MININET_USER = TOOLS_SYSTEM_USER
-MININET_PASSWORD = TOOLS_SYSTEM_PASSWORD
-MININET_PROMPT = TOOLS_SYSTEM_PROMPT
-PROMPT = '>' # TODO: remove this as it's vague. need to fix any occurances of it first.
+++ /dev/null
-*** Variables ***
-# DIDM suite variables
-${DEVICE_IP} ${TOOLS_SYSTEM_IP}
-${MININET} ${DEVICE_IP}
-${DEVICE_USER} ${TOOLS_SYSTEM_USER}
-${MININET_USER} ${DEVICE_USER}
-${DEVICE_PASSWORD} ${TOOLS_SYSTEM_PASSWORD}
-${MININET_PASSWORD} ${DEVICE_PASSWORD}
-${MININET_PROMPT} ${TOOLS_SYSTEM_PROMPT}
-${DEVICE_TYPE} mininet
-${DEVICE_DESCRIPTION} None
-${DEVICE_HW_INFO} Open vSwitch
-${DEVICE_SW_INFO} 2.0.0
-${DEVICE_MANUFACTURE} Nicira, Inc.
-${DEVICE_SERIAL_NUMBER} None
exit 1
fi
cd ~
-pybot -d ${HOME} -v CONTROLLER:$1 -v MININET:$MYIP -v USER_HOME:${HOME} -v MININET_USER:${USER} ${HOME}/integration/test/csit/suites/base
+pybot -d ${HOME} -v ODL_SYSTEM_IP:$1 -v TOOLS_SYSTEM_IP:$MYIP -v USER_HOME:${HOME} -v TOOLS_SYSTEM_USER:${USER} ${HOME}/integration/test/csit/suites/base
sleep 120
./run.sh -status
cd ~
-pybot -d ${HOME} -v CONTROLLER:127.0.0.1 -v MININET:127.0.0.1 -v USER_HOME:${HOME} -v MININET_USER:${USER} ${HOME}/integration/test/csit/suites/base
+pybot -d ${HOME} -v ODL_SYSTEM_IP:127.0.0.1 -v TOOLS_SYSTEM_IP:127.0.0.1 -v USER_HOME:${HOME} -v TOOLS_SYSTEM_USER:${USER} ${HOME}/integration/test/csit/suites/base
cd ~/controller-base/opendaylight
./run.sh -stop