[VOL-4072] Added Dataplane Scenarios to DT Soak Testing
Change-Id: If6cc184cb2d7c865f3f6f6d91e19df1421c0cbd9
diff --git a/libraries/utils.robot b/libraries/utils.robot
index b345b0f..6680a34 100755
--- a/libraries/utils.robot
+++ b/libraries/utils.robot
@@ -544,6 +544,23 @@
... sudo kill -9 `pidof iperf`
... ${src['ip']} ${src['user']} ${src['pass']} ${src['container_type']} ${src['container_name']}
+Setup Soak
+ [Documentation] Pre-test Setup for Soak Job
+ ${olt_ids} Create List
+ FOR ${I} IN RANGE 0 ${num_olts}
+ ${olt_serial_number}= Set Variable ${list_olts}[${I}][sn]
+ ${olt_device_id}= Get Device ID From SN ${olt_serial_number}
+ ${logical_id}= Get Logical Device ID From SN ${olt_serial_number}
+ ${of_id}= Wait Until Keyword Succeeds ${timeout} 15s Validate OLT Device in ONOS
+ ... ${olt_serial_number}
+ ${nni_port}= Run Keyword And Continue On Failure Wait Until Keyword Succeeds ${timeout} 2s
+ ... Get NNI Port in ONOS ${of_id}
+ Set Global Variable ${nni_port}
+ ${olt} Create Dictionary device_id ${olt_device_id} logical_id ${logical_id}
+ ... of_id ${of_id} sn ${olt_serial_number}
+ Append To List ${olt_ids} ${olt}
+ END
+ Set Global Variable ${olt_ids}
Setup
[Documentation] Pre-test Setup
diff --git a/tests/dt-workflow/Voltha_DT_FailureScenarios.robot b/tests/dt-workflow/Voltha_DT_FailureScenarios.robot
index 0aef9c0..a6d2bf7 100755
--- a/tests/dt-workflow/Voltha_DT_FailureScenarios.robot
+++ b/tests/dt-workflow/Voltha_DT_FailureScenarios.robot
@@ -538,24 +538,6 @@
... ${List_ONU_Serial} ${onu_flows}
*** Keywords ***
-Setup Soak
- [Documentation] Pre-test Setup for Soak Job
- ${olt_ids} Create List
- FOR ${I} IN RANGE 0 ${num_olts}
- ${olt_serial_number}= Set Variable ${list_olts}[${I}][sn]
- ${olt_device_id}= Get Device ID From SN ${olt_serial_number}
- ${logical_id}= Get Logical Device ID From SN ${olt_serial_number}
- ${of_id}= Wait Until Keyword Succeeds ${timeout} 15s Validate OLT Device in ONOS
- ... ${olt_serial_number}
- ${nni_port}= Run Keyword And Continue On Failure Wait Until Keyword Succeeds ${timeout} 2s
- ... Get NNI Port in ONOS ${of_id}
- Set Global Variable ${nni_port}
- ${olt} Create Dictionary device_id ${olt_device_id} logical_id ${logical_id}
- ... of_id ${of_id} sn ${olt_serial_number}
- Append To List ${olt_ids} ${olt}
- END
- Set Global Variable ${olt_ids}
-
Setup Suite
[Documentation] Set up the test suite
Common Test Suite Setup
diff --git a/tests/dt-workflow/Voltha_DT_PODTests.robot b/tests/dt-workflow/Voltha_DT_PODTests.robot
index 0db4600..7f03385 100644
--- a/tests/dt-workflow/Voltha_DT_PODTests.robot
+++ b/tests/dt-workflow/Voltha_DT_PODTests.robot
@@ -439,15 +439,15 @@
Data plane verification using TCP for DT
[Documentation] Test bandwidth profile is met and not exceeded for each subscriber.
... Assumes iperf3 and jq installed on client and iperf -s running on DHCP server
- [Tags] dataplaneDt BandwidthProfileTCPDt VOL-3061
+ [Tags] dataplaneDt BandwidthProfileTCPDt VOL-3061 soakDataplane
[Setup] Start Logging BandwidthProfileTCPDt
[Teardown] Run Keywords Collect Logs
... AND Stop Logging BandwidthProfileTCPDt
Pass Execution If '${has_dataplane}'=='False' Bandwidth profile validation can be done only in
... physical pod. Skipping this test in BBSIM.
- Delete All Devices And Verify
+ Run Keyword If 'SOAK_TEST'=='False' Clear All Devices Then Create New Device
+ ... ELSE Setup Soak
Run Keyword If ${has_dataplane} Clean Up Linux
- setup
Wait Until Keyword Succeeds ${timeout} 2s Perform Sanity Test DT
#${of_id}= Wait Until Keyword Succeeds ${timeout} 15s Validate OLT Device in ONOS
@@ -500,7 +500,7 @@
Data plane verification using UDP for DT
[Documentation] Test bandwidth profile is met and not exceeded for each subscriber.
... Assumes iperf3 and jq installed on client and iperf -s running on DHCP server
- [Tags] dataplaneDt BandwidthProfileUDPDt VOL-3061
+ [Tags] dataplaneDt BandwidthProfileUDPDt VOL-3061 soakDataplane
[Setup] Start Logging BandwidthProfileUDPDt
[Teardown] Run Keywords Collect Logs
... AND Stop Logging BandwidthProfileUDPDt
@@ -571,7 +571,7 @@
... Install jq tool to read json file, where test suite is being running
... This test sends TCP packets with pbits between 0 and 7 and validates that
... the pbits are preserved by the PON.
- [Tags] dataplaneDt TechProfileDt VOL-3291
+ [Tags] dataplaneDt TechProfileDt VOL-3291 soakDataplane
[Setup] Start Logging TechProfileDt
[Teardown] Run Keywords Collect Logs
... AND Stop Logging TechProfileDt