Commit fb957484 authored by Raphael Defosseux's avatar Raphael Defosseux

CI: intermediate commit

Signed-off-by: default avatarRaphael Defosseux <raphael.defosseux@eurecom.fr>
parent 97ae4300
...@@ -1386,6 +1386,13 @@ class OaiCiTest(): ...@@ -1386,6 +1386,13 @@ class OaiCiTest():
SSH.open(EPC.IPAddress, EPC.UserName, EPC.Password) SSH.open(EPC.IPAddress, EPC.UserName, EPC.Password)
SSH.command('cd ' + EPC.SourceCodePath, '\$', 5) SSH.command('cd ' + EPC.SourceCodePath, '\$', 5)
SSH.command('cd scripts', '\$', 5) SSH.command('cd scripts', '\$', 5)
# In case of a docker-based deployment, we need to ping from the trf-gen container
launchFromTrfContainer = False
if re.match('OAI-Rel14-Docker', EPC.Type, re.IGNORECASE):
launchFromTrfContainer = True
if launchFromTrfContainer:
ping_status = SSH.command('docker exec -it prod-trf-gen /bin/bash -c "ping ' + self.ping_args + ' ' + UE_IPAddress + '" 2>&1 | tee ping_' + self.testCase_id + '_' + device_id + '.log', '\$', int(ping_time[0])*1.5)
else:
ping_status = SSH.command('stdbuf -o0 ping ' + self.ping_args + ' ' + UE_IPAddress + ' 2>&1 | stdbuf -o0 tee ping_' + self.testCase_id + '_' + device_id + '.log', '\$', int(ping_time[0])*1.5) ping_status = SSH.command('stdbuf -o0 ping ' + self.ping_args + ' ' + UE_IPAddress + ' 2>&1 | stdbuf -o0 tee ping_' + self.testCase_id + '_' + device_id + '.log', '\$', int(ping_time[0])*1.5)
else: else:
cmd = 'ping ' + self.ping_args + ' ' + UE_IPAddress + ' 2>&1 > ping_' + self.testCase_id + '_' + device_id + '.log' cmd = 'ping ' + self.ping_args + ' ' + UE_IPAddress + ' 2>&1 > ping_' + self.testCase_id + '_' + device_id + '.log'
...@@ -2028,7 +2035,8 @@ class OaiCiTest(): ...@@ -2028,7 +2035,8 @@ class OaiCiTest():
SSH.command('adb -s ' + device_id + ' shell "ls /data/local/tmp"', '\$', 5) SSH.command('adb -s ' + device_id + ' shell "ls /data/local/tmp"', '\$', 5)
else: else:
SSH.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "ls /data/local/tmp"\'', '\$', 60) SSH.command('ssh ' + self.UEDevicesRemoteUser[idx] + '@' + self.UEDevicesRemoteServer[idx] + ' \'adb -s ' + device_id + ' shell "ls /data/local/tmp"\'', '\$', 60)
result = re.search('iperf3', SSH.getBefore()) # DEBUG: disabling iperf3 usage for the moment
result = re.search('iperf4', SSH.getBefore())
if result is None: if result is None:
result = re.search('iperf', SSH.getBefore()) result = re.search('iperf', SSH.getBefore())
if result is None: if result is None:
...@@ -2105,6 +2113,10 @@ class OaiCiTest(): ...@@ -2105,6 +2113,10 @@ class OaiCiTest():
launchFromEpc = True launchFromEpc = True
if re.match('OAI-Rel14-CUPS', EPC.Type, re.IGNORECASE): if re.match('OAI-Rel14-CUPS', EPC.Type, re.IGNORECASE):
launchFromEpc = False launchFromEpc = False
# When using a docker-based deployment, IPERF client shall be launched from trf container
launchFromTrfContainer = False
if re.match('OAI-Rel14-Docker', EPC.Type, re.IGNORECASE):
launchFromTrfContainer = True
if launchFromEpc: if launchFromEpc:
SSH.open(EPC.IPAddress, EPC.UserName, EPC.Password) SSH.open(EPC.IPAddress, EPC.UserName, EPC.Password)
SSH.command('cd ' + EPC.SourceCodePath + '/scripts', '\$', 5) SSH.command('cd ' + EPC.SourceCodePath + '/scripts', '\$', 5)
...@@ -2129,6 +2141,15 @@ class OaiCiTest(): ...@@ -2129,6 +2141,15 @@ class OaiCiTest():
self.Iperf_analyzeV3Output(lock, UE_IPAddress, device_id, statusQueue,SSH) self.Iperf_analyzeV3Output(lock, UE_IPAddress, device_id, statusQueue,SSH)
else: else:
if launchFromEpc: if launchFromEpc:
if launchFromTrfContainer:
if self.ueIperfVersion == self.dummyIperfVersion:
prefix = ''
else:
prefix = ''
if self.ueIperfVersion == '2.0.5':
prefix = '/iperf-2.0.5/bin/'
iperf_status = SSH.command('docker exec -it prod-trf-gen /bin/bash -c "' + prefix + 'iperf -c ' + UE_IPAddress + ' ' + modified_options + '" 2>&1 | tee iperf_' + self.testCase_id + '_' + device_id + '.log', '\$', int(iperf_time)*5.0)
else:
iperf_status = SSH.command('stdbuf -o0 iperf -c ' + UE_IPAddress + ' ' + modified_options + ' 2>&1 | stdbuf -o0 tee iperf_' + self.testCase_id + '_' + device_id + '.log', '\$', int(iperf_time)*5.0) iperf_status = SSH.command('stdbuf -o0 iperf -c ' + UE_IPAddress + ' ' + modified_options + ' 2>&1 | stdbuf -o0 tee iperf_' + self.testCase_id + '_' + device_id + '.log', '\$', int(iperf_time)*5.0)
else: else:
if self.ueIperfVersion == self.dummyIperfVersion: if self.ueIperfVersion == self.dummyIperfVersion:
......
...@@ -65,6 +65,7 @@ class EPCManagement(): ...@@ -65,6 +65,7 @@ class EPCManagement():
self.testCase_id = '' self.testCase_id = ''
self.MmeIPAddress = '' self.MmeIPAddress = ''
self.containerPrefix = 'prod' self.containerPrefix = 'prod'
self.mmeConfFile = 'mme.conf'
#----------------------------------------------------------- #-----------------------------------------------------------
...@@ -127,7 +128,7 @@ class EPCManagement(): ...@@ -127,7 +128,7 @@ class EPCManagement():
logging.debug('Using the OAI EPC Release 14 MME in Docker') logging.debug('Using the OAI EPC Release 14 MME in Docker')
mySSH.command('docker exec -d ' + self.containerPrefix + '-oai-mme /bin/bash -c "nohup tshark -i eth0 -i lo:s10 -w /tmp/mme_check_run.pcap 2>&1 > /dev/null"', '\$', 5) mySSH.command('docker exec -d ' + self.containerPrefix + '-oai-mme /bin/bash -c "nohup tshark -i eth0 -i lo:s10 -w /tmp/mme_check_run.pcap 2>&1 > /dev/null"', '\$', 5)
time.sleep(5) time.sleep(5)
mySSH.command('docker exec -d ' + self.containerPrefix + '-oai-mme /bin/bash -c "nohup ./bin/oai_mme -c ./etc/mme.conf > mme_check_run.log 2>&1"', '\$', 5) mySSH.command('docker exec -d ' + self.containerPrefix + '-oai-mme /bin/bash -c "nohup ./bin/oai_mme -c ./etc/' + self.mmeConfFile + ' > mme_check_run.log 2>&1"', '\$', 5)
elif re.match('OAI-Rel14-CUPS', self.Type, re.IGNORECASE): elif re.match('OAI-Rel14-CUPS', self.Type, re.IGNORECASE):
logging.debug('Using the OAI EPC Release 14 MME') logging.debug('Using the OAI EPC Release 14 MME')
mySSH.command('cd ' + self.SourceCodePath + '/scripts', '\$', 5) mySSH.command('cd ' + self.SourceCodePath + '/scripts', '\$', 5)
......
...@@ -283,6 +283,11 @@ def GetParametersFromXML(action): ...@@ -283,6 +283,11 @@ def GetParametersFromXML(action):
else: else:
ldpc.forced_workspace_cleanup=False ldpc.forced_workspace_cleanup=False
elif action == 'Initialize_MME':
string_field = test.findtext('option')
if (string_field is not None):
EPC.mmeConfFile = string_field
else: # ie action == 'Run_PhySim': else: # ie action == 'Run_PhySim':
ldpc.runargs = test.findtext('physim_run_args') ldpc.runargs = test.findtext('physim_run_args')
......
<!--
Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The OpenAirInterface Software Alliance licenses this file to You under
the OAI Public License, Version 1.1 (the "License"); you may not use this file
except in compliance with the License.
You may obtain a copy of the License at
http://www.openairinterface.org/?page_id=698
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
For more information about the OpenAirInterface (OAI) Software Alliance:
contact@openairinterface.org
-->
<testCaseList>
<htmlTabRef>epc-start-tab</htmlTabRef>
<htmlTabName>EPC-Start</htmlTabName>
<htmlTabIcon>log-in</htmlTabIcon>
<TestCaseRequestedList>
000100 000101 000102
</TestCaseRequestedList>
<TestCaseExclusionList>
</TestCaseExclusionList>
<testCase id="000100">
<class>Initialize_HSS</class>
<desc>Initialize HSS</desc>
</testCase>
<testCase id="000101">
<class>Initialize_MME</class>
<desc>Initialize MME</desc>
<option>mme-verizon.conf</option>
</testCase>
<testCase id="000102">
<class>Initialize_SPGW</class>
<desc>Initialize SPGW</desc>
</testCase>
</testCaseList>
<!--
Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The OpenAirInterface Software Alliance licenses this file to You under
the OAI Public License, Version 1.1 (the "License"); you may not use this file
except in compliance with the License.
You may obtain a copy of the License at
http://www.openairinterface.org/?page_id=698
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
For more information about the OpenAirInterface (OAI) Software Alliance:
contact@openairinterface.org
030101 040301 040501 040603 040604 040605 040606 040607 040641 040642 040643 040644 040401 040201 030201
-->
<testCaseList>
<htmlTabRef>test-05-tm1</htmlTabRef>
<htmlTabName>Test-05MHz-TM1</htmlTabName>
<htmlTabIcon>tasks</htmlTabIcon>
<TestCaseRequestedList>
030201
040101
030101 040301 000001 040501 040603 040401 030201
</TestCaseRequestedList>
<TestCaseExclusionList></TestCaseExclusionList>
<testCase id="000001">
<class>IdleSleep</class>
<desc>Sleep</desc>
<idle_sleep_time_in_sec>5</idle_sleep_time_in_sec>
</testCase>
<testCase id="030101">
<class>Initialize_eNB</class>
<desc>Initialize eNB (FDD/Band7/5MHz)</desc>
<Initialize_eNB_args>-O ci-scripts/conf_files/enb.band7.tm1.25PRB.usrpb210.conf --eNBs.[0].plmn_list.[0].mcc 311 --eNBs.[0].plmn_list.[0].mnc 480 --eNBs.[0].plmn_list.[0].mnc_length 3 --eNBs.[0].component_carriers.[0].Nid_cell 10</Initialize_eNB_args>
</testCase>
<testCase id="030201">
<class>Terminate_eNB</class>
<desc>Terminate eNB</desc>
</testCase>
<testCase id="040101">
<class>Initialize_UE</class>
<desc>Initialize UE</desc>
</testCase>
<testCase id="040201">
<class>Terminate_UE</class>
<desc>Terminate UE</desc>
</testCase>
<testCase id="040301">
<class>Attach_UE</class>
<desc>Attach UE</desc>
</testCase>
<testCase id="040401">
<class>Detach_UE</class>
<desc>Detach UE</desc>
</testCase>
<testCase id="040501">
<class>Ping</class>
<desc>ping (5MHz - 20 sec)</desc>
<ping_args>-c 20</ping_args>
<ping_packetloss_threshold>5</ping_packetloss_threshold>
</testCase>
<testCase id="040603">
<class>Iperf</class>
<desc>iperf (5MHz - DL/15Mbps/UDP)(30 sec)(balanced profile)</desc>
<iperf_args>-u -b 15M -t 30 -i 1</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>balanced</iperf_profile>
</testCase>
<testCase id="040604">
<class>Iperf</class>
<desc>iperf (5MHz - DL/15Mbps/UDP)(30 sec)(single-ue profile)</desc>
<iperf_args>-u -b 15M -t 30 -i 1</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040605">
<class>Iperf</class>
<desc>iperf (5MHz - DL/15Mbps/UDP)(30 sec)(unbalanced profile)</desc>
<iperf_args>-u -b 15M -t 30 -i 1</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>unbalanced</iperf_profile>
</testCase>
<testCase id="040606">
<class>Iperf</class>
<desc>iperf (5MHz - DL/TCP)(30 sec)(single-ue profile)</desc>
<iperf_args>-t 30 -i 1 -fm</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040607">
<class>Iperf</class>
<desc>iperf (5MHz - DL/TCP)(30 sec)(balanced profile)</desc>
<iperf_args>-t 30 -i 1 -fm</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>balanced</iperf_profile>
</testCase>
<testCase id="040641">
<class>Iperf</class>
<desc>iperf (5MHz - UL/9Mbps/UDP)(30 sec)(balanced profile)</desc>
<iperf_args>-u -b 9M -t 30 -i 1 -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>balanced</iperf_profile>
</testCase>
<testCase id="040642">
<class>Iperf</class>
<desc>iperf (5MHz - UL/9Mbps/UDP)(30 sec)(single-ue profile)</desc>
<iperf_args>-u -b 9M -t 30 -i 1 -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040643">
<class>Iperf</class>
<desc>iperf (5MHz - UL/TCP)(30 sec)(single-ue profile)</desc>
<iperf_args>-t 30 -i 1 -fm -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040644">
<class>Iperf</class>
<desc>iperf (5MHz - UL/TCP)(30 sec)(balanced profile)</desc>
<iperf_args>-t 30 -i 1 -fm -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>balanced</iperf_profile>
</testCase>
</testCaseList>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment