Commit e3a8e68e authored by Rohit Gupta's avatar Rohit Gupta

Merge branch 'feature-34-test_framework' into develop

parents ef498d78 d7e31be9
......@@ -133,9 +133,6 @@ else (CMAKE_SYSTEM_PROCESSOR STREQUAL "armv7l")
if (CPUINFO MATCHES "avx2")
set(C_FLAGS_PROCESSOR "${C_FLAGS_PROCESSOR} -mavx2")
endif()
if (CPUINFO MATCHES "sse4_2")
set(C_FLAGS_PROCESSOR "${C_FLAGS_PROCESSOR} -msse4.2")
endif()
if (CPUINFO MATCHES "sse4_1")
set(C_FLAGS_PROCESSOR "${C_FLAGS_PROCESSOR} -msse4.1")
endif()
......@@ -149,8 +146,8 @@ set(C_FLAGS_PROCESSOR " ${C_FLAGS_PROCESSOR} ${CFLAGS_PROCESSOR_USER}")
Message("C_FLAGS_PROCESSOR is ${C_FLAGS_PROCESSOR}")
if (CMAKE_SYSTEM_PROCESSOR MATCHES "x86")
if ( (NOT( C_FLAGS_PROCESSOR MATCHES "ssse3")) OR (NOT( C_FLAGS_PROCESSOR MATCHES "msse4.1")) OR (NOT( C_FLAGS_PROCESSOR MATCHES "msse4.2")) )
Message(FATAL_ERROR "For x86 Architecture, you must have following flags: -mssse3 -msse4.1 -msse4.2. The current detected flags are: ${C_FLAGS_PROCESSOR}. You can pass the flags manually in build script, for example: ./build_oai --cflags_processor \"-mssse3 -msse4.1 -msse4.2\" ")
if ( (NOT( C_FLAGS_PROCESSOR MATCHES "ssse3")) OR (NOT( C_FLAGS_PROCESSOR MATCHES "msse4.1")) )
Message(FATAL_ERROR "For x86 Architecture, you must have following flags: -mssse3 -msse4.1. The current detected flags are: ${C_FLAGS_PROCESSOR}. You can pass the flags manually in build script, for example: ./build_oai --cflags_processor \"-mssse3 -msse4.1\" ")
endif()
endif()
......
......@@ -6,41 +6,50 @@ Obj.# Case# Test# Description
01 pre-commit test case
01 01 Build OAI
01 01 01 Build oaisim.Rel8
01 01 02 Build oaisim.Rel8 + network device driver(nasmesh_fix)
01 01 03 Build (lte-softmodem.Rel8.EXMIMO + lte-softmodem.Rel10.EXMIMO + lte-softmodem.Rel10.USRP)
01 01 04 Build (dlsim.Rel10 + ulsim.Rel10 + pucchsim.Rel10 + prachsim.Rel10 + pdcchsim.Rel10 + pbchsim.Rel10 + mbmssim.Rel10
01 01 02 Build oaisim.Rel10
01 01 03 Build oaisim_noS1.Rel10
01 01 10 Build lte-softmodem_noS1.USRP.Rel10
01 01 11 Build lte-softmodem_noS1.EXMIMO.Rel10
01 01 12 Build lte-softmodem_noS1.BLADERF.Rel10
01 01 13 Build lte-softmodem_noS1.ETHERNET.Rel10
01 01 20 Build lte-softmodem.USRP.Rel10
01 01 21 Build lte-softmodem.EXMIMO.Rel10
01 01 22 Build lte-softmodem.BLADERF.Rel10
01 01 23 Build lte-softmodem.ETHERNET.Rel10
01 01 30 Build (dlsim.Rel10 + ulsim.Rel10 + pucchsim.Rel10 + prachsim.Rel10 + pdcchsim.Rel10 + pbchsim.Rel10 + mbmssim.Rel10
secu_knas_encrypt_eia1.Rel10 secu_kenb.Rel10 aes128_ctr_encrypt.Rel10 aes128_ctr_decrypt.Rel10 secu_knas_encrypt_eea2.Rel10
secu_knas.Rel10 secu_knas_encrypt_eea1.Rel10 kdf.Rel10 aes128_cmac_encrypt.Rel10 secu_knas_encrypt_eia2.Rel10)
01 01 06 Build oaisim.Rel8 + ITTI
01 01 07 Build oaisim.Rel10
01 01 08 Build oaisim.Rel10 + ITTI
01 01 20 Build Nasmesh
01 01 30 Build RRH Gateway
01 02 Run OAISIM Rel10 (TDD + 5MHz/10MHz/20MHz + TM 1,2,5,6), and check the operation
01 02 00 Run OAISIM Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit
01 02 01 Run OAISIM Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors
01 02 02 Run OAISIM Rel10 TDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit
01 02 03 Run OAISIM Rel10 TDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors
01 02 04 Run OAI Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) without PHY_ABSTRACTION mode, ping from from eNB to UE,
01 01 40 Build RRH Gateway for USRP (Rel 10)
01 01 41 Build RRH Gateway for EXMIMO (Rel 10)
01 01 42 Build RRH Gateway for BLADERF (Rel 10)
01 02 Run OAISIM-NOS1 Rel10 (TDD + 5MHz/10MHz/20MHz + TM 1,2,5,6), and check the operation
01 02 00 Run OAISIM-NOS1 Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit
01 02 01 Run OAISIM-NOS1 Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors
01 02 02 Run OAISIM-NOS1 Rel10 TDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit
01 02 03 Run OAISIM-NOS1 Rel10 TDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors
01 02 04 Run OAISIM-NOS1 Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) without PHY_ABSTRACTION mode, ping from from eNB to UE,
and for check for no packet losses
01 02 05 Run OAI Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode, send ping from from eNB to UE,
01 02 05 Run OAISIM-NOS1 Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode, send ping from from eNB to UE,
and check for no packet losses
01 03 Run OAISIM Rel10 (FDD + 5MHz/10MHz/20MHz + TM 1,2,5,6), and check the operation
01 03 00 Run OAISIM Rel10 FDD, 1 eNB + 1 UE 1 eNB (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit
01 03 01 Run OAISIM Rel10 FDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors
01 03 02 Run OAISIM Rel10 FDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit
01 03 03 Run OAISIM Rel10 FDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors
01 03 04 Run OAI Rel10 FDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) without PHY_ABSTRACTION mode, ping from from eNB to UE,
01 03 Run OAISIM-NOS1 Rel10 (FDD + 5MHz/10MHz/20MHz + TM 1,2,5,6), and check the operation
01 03 00 Run OAISIM-NOS1 Rel10 FDD, 1 eNB + 1 UE 1 eNB (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit
01 03 01 Run OAISIM-NOS1 Rel10 FDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors
01 03 02 Run OAISIM-NOS1 Rel10 FDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit
01 03 03 Run OAISIM-NOS1 Rel10 FDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors
01 03 04 Run OAISIM-NOS1 Rel10 FDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) without PHY_ABSTRACTION mode, ping from from eNB to UE,
and for check for no packet losses
01 03 05 Run OAI Rel10 FDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode, send ping from from eNB to UE,
01 03 05 Run OAISIM-NOS1 Rel10 FDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode, send ping from from eNB to UE,
and check for no packet losses
01 04 MBSFN Tests
01 04 OAISIM-NOS1 MBSFN Tests
01 04 00 Check if eMBMS procedure is not finished completely, make sure that the SIB13/MCCH have been correclty received by UEs
01 04 01 Check if eMBMS multicast/broadcast data is received, make sure that the SIB13/MCCH/MTCH have been correclty received by UEs
01 04 02 Check for eMBMS multicast/broadcast data received in fdd mode, make sure that the SIB13/MCCH/MTCH have been correctly
......@@ -88,20 +97,29 @@ Obj.# Case# Test# Description
01 51 06 mbmssim (TBD)
01 55 lte-softmodem tests with ALU EPC w/ Bandrich COTS UE
01 55 00 FDD 5MHz UL Throughput for 60 sec
01 55 00 FDD 10MHz UL Throughput for 60 sec
01 55 00 FDD 20MHz UL Throughput for 60 sec
01 55 00 FDD 5MHz DL Throughput for 60 sec
01 55 00 FDD 10MHz DL Throughput for 60 sec
01 55 00 FDD 20MHz DL Throughput for 60 sec
01 55 lte-softmodem tests with USRP B210 RF as eNB and ALU EPC w/ Bandrich COTS UE for `TX/1RX, 1TX/2RX, 2TX/1RX 2TX/2RX
01 55 00 Band 7 FDD 5MHz UL Throughput for 60 sec for 1TX/1RX
01 55 00 Band 7 FDD 10MHz UL Throughput for 60 sec
01 55 00 Band 7 FDD 20MHz UL Throughput for 60 sec
01 55 00 Band 7 FDD 5MHz DL Throughput for 60 sec
01 55 00 Band 7 FDD 10MHz DL Throughput for 60 sec
01 55 00 Band 7 FDD 20MHz DL Throughput for 60 sec
01 56 lte-softmodem tests with USRP B210 RF as eNB and OAI EPC (eNB and EPC are on same machines) w/ Bandrich COTS UE
01 57 lte-softmodem tests with USRP B210 RF as eNB and OAI EPC (eNB and EPC are on different machines) w/ Bandrich COTS UE
01 56 lte-softmodem tests with OAI EPC (eNB and EPC are on same machines) w/ Bandrich COTS UE
01 58 lte-softmodem tests with USRP X310 RF as eNB and ALU EPC w/ Bandrich COTS UE for `TX/1RX, 1TX/2RX, 2TX/1RX 2TX/2RX
01 59 lte-softmodem tests with USRP X310 RF as eNB and OAI EPC (eNB and EPC are on same machines) w/ Bandrich COTS UE
01 57 lte-softmodem tests with OAI EPC (eNB and EPC are on different machines) w/ Bandrich COTS UE
01 61 lte-softmodem tests with USRP X310 RF as eNB and OAI EPC (eNB and EPC are on different machines) w/ Bandrich COTS UE
01 61 lte-softmodem tests with EXMIMO RF as eNB and ALU EPC w/ Bandrich COTS UE
01 62 lte-softmodem tests with EXMIMO RF as eNB and OAI EPC (eNB and EPC are on same machines) w/ Bandrich COTS UE
01 63 lte-softmodem tests with EXMIMO RF as eNB and OAI EPC (eNB and EPC are on different machines) w/ Bandrich COTS UE
01 58 lte-softmodem-noS1 tests
......
#******************************************************************************
# Eurecom OpenAirInterface
# Copyright(c) 1999 - 2013 Eurecom
# This program is free software; you can redistribute it and/or modify it
# under the terms and conditions of the GNU General Public License,
# version 2, as published by the Free Software Foundation.
# This program is distributed in the hope it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
# more details.
# You should have received a copy of the GNU General Public License along with
# this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA.
# The full GNU General Public License is included in this distribution in
# the file called "COPYING".
# Contact Information
# Openair Admin: openair_admin@eurecom.fr
# Openair Tech : openair_tech@eurecom.fr
# Forums : http://forums.eurecom.fsr/openairinterface
# Address : Eurecom, Compus SophiaTech 450, route des chappes, 06451 Biot, France
#*****************************************************************************
# \file core.py
# \brief OAI core testing class that provides various primitives to send/recv cmd to openair class searching for patterns and process the responses and tag the test case as passed/failed/skipped
# \author Navid Nikaein
# \date 2013
# \version 0.1
# @ingroup _test
import pexpect
import time
import re
import string
import sys
import os
import openair
import log
class core:
def __init__(self):
self.send_cr = 1
self.expect_echo = 0
self.expect_response = 1
self.flag_errors = 1
self.log = None
def clean(self, obj):
if type(obj) is str:
return obj
else:
return repr(obj)
def mark(self, marker):
if self.log:
print >> self.log, "\n\n{" + marker + "}\n\n"
def expected(self, expected, got):
return "================================= Failure ===================================\n"+\
"_________________________________ Expected __________________________________\n"+\
"--->" + expected + "<-\n" +\
"_________________________________ Received __________________________________\n"+\
"--->" + got + "<-\n" +\
"=============================================================================\n"
def unexpected(self, notexpected, got):
return "================================= Failure ===================================\n"+\
"__________________________ not expect to find _______________________________\n"+\
"---> " + self.clean(notexpected) + "\n" +\
"_________________________________ Received___________________________________\n"+\
"---> " + self.clean(got) + "\n" +\
"=============================================================================\n"
def failed(self, command, expect,debug):
time.sleep(2)
ret = "================================= Failure =================================\n"
ret +="_________________________________ Sent ____________________________________\n"
ret +="---> " + command + "\n"
ret +="______________________________Searching for _______________________________\n"
ret +="---> " + self.clean(expect) + "\n"
if debug >= 1 :
ret +="________________________________ Received _________________________________\n"
ret +="---> " + self.clean(self.oai.before) + "\n"
ret +="_______________________________ Remaining _________________________________\n"
ret +="---> " + self.clean(self.oai.after) + "\n"
ret +="===========================================================================\n"
return ret
def err(self, command):
return "============================ Error received ================================\n"+\
"__________________________________ Sent ____________________________________\n"+\
'---> ' + command + "\n"+\
"_________________________________ Error was ________________________________\n"+\
"---> " + self.oai.before + "\n" +\
"============================================================================\n"
def wait_quiet(self, timeout=0.5):
while 1:
try:
self.oai.expect(['..*'], timeout=0.5)
except pexpect.TIMEOUT, e:
return
# print '[Flushing ' + self.oai.after + ']'
# **************************Send*****************************
# 1) send a command and return, do not wait
# ************************************************************
def send_nowait(self, command, sudo=False):
rsp1 = self.prompt1
rsp2 = self.prompt2
if sudo == True:
command = 'echo \'' + self.password + '\' | sudo -S -E ' + command
self.wait_quiet()
if self.send_cr:
log.stats['cmd'] += 1
self.oai.sendline(command)
else:
self.oai.send(command)
# **************************Send*****************************
# 1) send a command
# 2) wait for a return prompt. Don't capture the response.
# 3) Check for error or timeout.
# ************************************************************
def send(self, command,sudo=False, timeout = 50, rsp1=None, rsp2=None,debug=0):
if not rsp1:
rsp1 = self.prompt1
if not rsp2:
rsp2 = self.prompt2
self.wait_quiet()
if sudo == True:
command = 'echo \'' + self.password + '\' | sudo -S -E ' + command
if self.send_cr:
log.stats['cmd'] += 1
self.oai.sendline(command)
else:
self.oai.send(command)
if self.expect_echo:
#cmd = self.oai.expect([re.escape(command), pexpect.TIMEOUT], timeout=timeout);
cmd = self.oai.expect_exact([command, pexpect.TIMEOUT], timeout=timeout);
if cmd != 0:
raise log.err(self.failed(command, command,debug))
if self.expect_response:
#index = self.oai.expect([re.escape(rsp1), re.escape(rsp2),'%', pexpect.TIMEOUT], timeout=timeout)
index = self.oai.expect_exact([rsp1, rsp2, pexpect.TIMEOUT], timeout=timeout)
if index == 0 or index == 1:
return 'OK'
elif index == 2:
#self.oai.expect([re.escape(rsp1), re.escape(rsp2), pexpect.TIMEOUT], timeout=timeout)
self.oai.expect_exact([rsp1, rsp2, pexpect.TIMEOUT], timeout=timeout)
if self.flag_errors:
raise log.err(self.err(command))
else:
return 'OK'
else:
raise log.err(self.failed(command, rsp1 + ' or ' + rsp2,debug))
# **************************send_recv*************************
# 1) send a command
# 2) wait for either rsp1 or rsp2 is found (normally prompts)
# 3) return everything seen before that
# ************************************************************
def send_recv(self, command, sudo=False, timeout=100, rsp1=None, rsp2=None,debug=0):
if not rsp1:
rsp1 = self.prompt1
if not rsp2:
rsp2 = self.prompt2
self.wait_quiet()
if sudo == True:
command = 'echo \'' + self.password + '\' | sudo -S -E ' + command
if self.send_cr:
log.stats['cmd'] += 1
self.oai.sendline(command)
else:
self.oai.send(command)
#index = self.oai.expect([re.escape(rsp1), re.escape(rsp2), pexpect.TIMEOUT], timeout=timeout);
index = self.oai.expect_exact([rsp1, rsp2, pexpect.TIMEOUT], timeout=timeout);
if index == 0 or index == 1 :
return self.oai.before
else:
raise log.err(self.failed(command, rsp1 + ' or ' + rsp2,debug))
# **************************send_expect*************************
# 1) send a command, and optionally specify a the time to wait
# 2) search for an expected pattern in the response
# 3) raise an error if not found
# **************************************************************
def send_expect(self, command, expect, sudo=False, delay = 50, rsp1=None, rsp2=None,debug=0):
if debug :
print command
print expect
print delay
rsp = self.send_recv(command, sudo, delay, rsp1, rsp2)
#print rsp
if (rsp.find(expect) != -1):
return 'Ok'
raise log.err(self.failed(command, expect,debug))
# **************************send_expect_re*************************
# 1) send a command, and optionally specify a the time to wait
# 2) search for an expected pattern defined by a regular expression in the response
# 3) return a error if raise_err flag is set and re not found, otherwise return 'Ok'
# *****************************************************************
def send_expect_re(self, command, expect, sudo=False, raise_err=1, delay = 50, rsp1=None, rsp2=None,debug=0):
rsp = self.send_recv(command, sudo, delay, rsp1, rsp2)
# print rsp
match = re.compile(expect).search(rsp)
if match:
return match
if raise_err:
raise log.err(self.failed(command, expect,debug))
else :
return None
# **************************send_expect*************************
# 1) send a command, and optionally specify a the time to wait
# 2) search for an expected pattern defined by a re in the response
# 3) return ok if not found
# **************************************************************
def send_expect_false(self, command, expect, sudo=False, delay = 5, rsp1=None, rsp2=None,debug=0):
rsp = self.send_recv(command, sudo, delay, rsp1, rsp2)
# print rsp
if (rsp.find(expect) == -1):
return 'OK'
raise log.err(self.failed(command, expect,debug))
# **************************send_wait*************************
# 1) send a command, and optionally specify a the time to wait
# 2) search for an expected pattern in the response
# 3) retry for a numretries if not found
# 4) return an error if not found after the numtries
# 3) return the response if found
# **************************************************************
def send_wait(self, command, expect, sudo=False, numretries=3, rsp1=None, rsp2=None,debug=0):
timer = 0
for i in range(numretries):
rsp = self.send_recv(command, sudo, 10, rsp1, rsp2)
if (rsp.find(expect) != -1):
return rsp;
time.sleep(2)
timer = timer+2
raise log.err(self.failed(command, expect,debug))
# **************************send_wait_re*************************
# 1) send a command, and optionally specify a the time to wait
# 2) search for an expected pattern defined by a re in the response
# 3) retry for a numretries if not found
# 4) return an error if not found after the numtries
# 3) return the response if found
# **************************************************************
def send_wait_re(self, command, expect, sudo=False, numretries=3, rsp1=None, rsp2=None,debug=0):
timer = 0
for i in range(numretries):
rsp = self.send_recv(command,sudo)
if re.compile(expect).search(rsp):
# print "Found in",i,"attempts"
return rsp;
time.sleep(2)
timer = timer+2
raise log.err(self.failed(command, expect,debug))
# **************************send_wait_false*************************
# 1) send a command, and optionally specify a the time to wait
# 2) search for an expect pattern in the response
# 3) return the response if not found
# 4) return an error if the pattern found after the numtries
# **************************************************************
def send_wait_false(self, command, expect, sudo=False, numretries=3, rsp1=None, rsp2=None,debug=0):
timer = 1
for i in range(numretries):
rsp = self.send_recv(command,sudo)
if (rsp.find(expect) == -1):
return rsp;
time.sleep(2)
timer = timer+2
raise log.err(self.failed(command, expect,debug))
# **************************send_wait_false*************************
# 1) send a command, and optionally specify a the time to wait
# 2) search for an expect pattern defined by a re in the response
# 3) return the response if not found
# 4) return an error if the pattern found after the numtries
# **************************************************************
def send_wait_false_re(self, command, expect, sudo=False, numretries=3, rsp1=None, rsp2=None,debug=0):
timer = 0
for i in range(numretries):
rsp = self.send_recv(command,sudo)
if not re.compile(expect).search(rsp):
return rsp;
time.sleep(2)
timer = timer+2
raise log.err(self.failed(command, expect,debug))
# **************************find*************************
# 1) find an exact pattern in a given string
# 2) raise an error if not found
# **************************************************************
def find(self, string, pattern):
word = string.replace(pattern,'*','\*')
words = string.replace(word,' ','\s*')
if re.search(words,string):
pass
else:
raise log.err(string)
# **************************find_false**************************
# 1) find an exact pattern in a given string
# 2) raise an error if found
# **************************************************************
def find_false(self, string, pattern):
if string.find(pattern) != -1:
raise log.err(string)
# **************************find_re*************************
# 1) find an exact re pattern in a given string
# 2) raise an error if not found
# **************************************************************
def find_re(self, string, pattern):
if not re.compile(pattern).search(string):
raise log.err(string)
# **************************find_false_re*************************
# 1) find an exact re pattern in a given string
# 2) raise an error if found
# **************************************************************
def find_false_re(self, string, pattern):
if re.compile(pattern).search(string):
raise log.err(string)
#******************************************************************************
# Eurecom OpenAirInterface
# Copyright(c) 1999 - 2013 Eurecom
# This program is free software; you can redistribute it and/or modify it
# under the terms and conditions of the GNU General Public License,
# version 2, as published by the Free Software Foundation.
# This program is distributed in the hope it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
# more details.
# You should have received a copy of the GNU General Public License along with
# this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA.
# The full GNU General Public License is included in this distribution in
# the file called "COPYING".
# Contact Information
# Openair Admin: openair_admin@eurecom.fr
# Openair Tech : openair_tech@eurecom.fr
# Forums : http://forums.eurecom.fsr/openairinterface
# Address : Eurecom, Compus SophiaTech 450, route des chappes, 06451 Biot, France
#*****************************************************************************
# \file log.py
# \brief provides primitives and defines how the logs and statistics are generated
# \author Navid Nikaein
# \date 2013
# \version 0.1
# @ingroup _test
import sys
import re
import time
import datetime
import array
import xml.etree.ElementTree as ET
debug = False
docfile = ''
start_time = time.time()
testcase_starttime = start_time
debug = 0
stats = {'passed':0, 'failed':0, 'skipped':0, 'internal_errors':0, 'cmd':0}
# xml result (jUnit like)
xUnitTestsuites = ET.Element( 'testsuites' )
xUnitTestsuite = ET.SubElement( xUnitTestsuites, 'testsuite' )
xUnitTestsuite.set( 'name', 'OAI' )
xUnitTestsuite.set( 'timestamp', datetime.datetime.fromtimestamp(start_time).strftime('%Y-%m-%dT%H:%M:%S') )
xUnitTestsuite.set( 'hostname', 'localhost' )
#xUnitSystemOut = ET.SubElement( xUnitTestsuite, 'system-out' )
class bcolors:
header = '\033[95m'
okblue = '\033[94m'
okgreen = '\033[92m'
warning = '\033[93m'
fail = '\033[91m'
normal = '\033[0m'
def __init__(self):
if not sys.stdout.isatty():
self.disable()
def disable(self):
self.header = ''
self.okblue = ''
self.okgreen = ''
self.warning = ''
self.fail = ''
self.normal = ''
class err(Exception):
def __init__(self, value):
self.value = value
def __str__(self):
return repr(self.value)
def writefile(logfile, message):
F_testlog = open(logfile, 'a')
F_testlog.write(message + '\n')
F_testlog.close()
def sleep(seconds):
time.sleep(seconds)
def start():
"""Start the timer for the following testcase."""
global testcase_starttime
testcase_starttime = time.time()
def set_debug_level(level):
debug = level
def statistics(logfile):
global start_time
#if stats['passed'] == 0:
# print "no test executed...exiting"
# sys.exit()
total_tests = stats['passed'] + stats['failed'] + stats['skipped']
total_ex_tests = stats['passed'] + stats['failed']
elapsed_time = time.gmtime(time.time() - start_time)
print '\n'
log_record('info', '===============================================')
log_record('info', 'Total tests performed ' + repr(total_tests))
log_record('info', 'Tests passed ' + repr(stats['passed']))
log_record('info', 'Tests failed ' + repr(stats['failed']))
log_record('info', 'Tests skipped ' + repr(stats['skipped']))
log_record('info', '')
log_record('info', 'Total commands sent ' + repr(stats['cmd']))
log_record('info', 'Total elapsed time (h:m:s) ' + time.strftime('%H:%M:%S', elapsed_time))
log_record('info', '===============================================')
log_record('info', 'Testing pass rate ' + repr((stats['passed'] * 100) / total_tests) + '%')
log_record('info', '===============================================')
writefile(logfile, '\n=====================Results===================')
writefile(logfile, 'Total tests performed ' + repr(total_tests))
writefile(logfile, 'Tests passed ' + repr(stats['passed']))
writefile(logfile, 'Tests failed ' + repr(stats['failed']))
writefile(logfile, 'Tests skipped ' + repr(stats['skipped']))
writefile(logfile, '')
writefile(logfile, 'Total commands sent ' + repr(stats['cmd']))
writefile(logfile, 'Total elapsed time (h:m:s) ' + time.strftime('%H:%M:%S', elapsed_time))
writefile(logfile, '===============================================')
writefile(logfile, 'Testing pass rate ' + repr((stats['passed'] * 100) / total_tests) + '%')
writefile(logfile, '===============================================\n')
xUnitTestsuite.set( 'tests', repr(total_tests) )
xUnitTestsuite.set( 'failures', repr(stats['failed']) )
xUnitTestsuite.set( 'skipped', repr(stats['skipped']) )
xUnitTestsuite.set( 'errors', '0' )
time_delta = datetime.datetime.now() - datetime.datetime.fromtimestamp(start_time)
xUnitTestsuite.set( 'time', repr(time_delta.total_seconds()) )
writefile( logfile + '.xml', ET.tostring( xUnitTestsuites, encoding="utf-8", method="xml" ) )
def log_record(level, message):
ts = time.strftime('%d %b %Y %H:%M')
message = ts + ' [' + level + '] ' + message
if level == 'passed' :
print bcolors.okgreen + message + bcolors.normal
elif level == 'failed' :
print bcolors.fail + message + bcolors.normal
elif level == 'skipped' :
print bcolors.warning + message + bcolors.normal
else :
print message
def fail(case, testnum, testname, conf, message, diag, output,trace):
# report(case, testnum, testname, conf, 'failed', output, diag, message)
report(case, testnum, testname, conf, 'failed', output, diag)
log_record('failed', case + testnum + ' : ' + testname + ' ('+ conf+')')
if message :
log_record('failed', "Output follows:\n" + message )
if trace :
log_record('failed', "trace file can be found in " + trace + "\n" )
stats['failed'] += 1
def failquiet(case, testnum, testname, conf):
log_record('failed', case + testnum + ' :' + testname + ' ('+ conf+')')
stats['failed'] += 1
def ok(case, testnum, testname, conf, message, output):
report(case, testnum, testname, conf, 'passed', output)
log_record('passed', case + testnum + ' : ' + testname + ' ('+ conf+')')
if message :
print bcolors.okgreen + message + bcolors.normal
stats['passed'] += 1
def skip(case, testnum, testname, conf, message=None, diag=None, output=None):
log_record('skipped', case + testnum + ' :' + testname + ' ('+ conf+')')
report(case, testnum, testname, conf, 'skipped', output, diag)
if message :
log_record('skipped', "Output follows:\n" + message )
if diag :
log_record('skipped', "Diagnostic: \n" + diag )
stats['skipped'] += 1
def report(case, test, name, conf, status, output, diag=None, desc=None):
writefile (output, '[' +status+ '] ' + case + test + ' : ' + name + ' ('+ conf+')')
if diag :
writefile (output, '-------> ' + diag)
if desc:
writefile(output, desc)
#log_record('report', + case + test + ' documented')
e = ET.SubElement( xUnitTestsuite, 'testcase' )
e.set( 'name', case + '_' + test + '_' + name )
e.set( 'classname', 'shellscript' )
e.set( 'time', repr( time.time() - testcase_starttime ) )
if status == 'failed':
e = ET.SubElement( e, 'failure' )
e.set( 'message', 'failed' )
e.text = diag
if status == 'skipped':
e = ET.SubElement( e, 'skipped' )
#******************************************************************************
# Eurecom OpenAirInterface
# Copyright(c) 1999 - 2013 Eurecom
# This program is free software; you can redistribute it and/or modify it
# under the terms and conditions of the GNU General Public License,
# version 2, as published by the Free Software Foundation.
# This program is distributed in the hope it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
# more details.
# You should have received a copy of the GNU General Public License along with
# this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA.
# The full GNU General Public License is included in this distribution in
# the file called "COPYING".
# Contact Information
# Openair Admin: openair_admin@eurecom.fr
# Openair Tech : openair_tech@eurecom.fr
# Forums : http://forums.eurecom.fsr/openairinterface
# Address : Eurecom, Compus SophiaTech 450, route des chappes, 06451 Biot, France
#*****************************************************************************
# \file openair.py
# \brief class that define the oaisim class and its attributes
# \author Navid Nikaein
# \date 2013
# \version 0.1
# @ingroup _test
import pexpect
import pxssh
import time
import os
import array
import shutil
import subprocess
import sys
import traceback
# import call
from core import *
SHELL = '/bin/bash'
class openair(core):
def __init__(self, hostname, address):
self.error = '% '
self.hostname = hostname
self.address = address
self.localhost = None
core.__init__(self)
@property
def localhost(self):
if self.localhost :
return self.localhost
elif self.hostname in ['localhost', '127.0.0.7', '::1'] :
self.localhost = self.hostname
return self.localhost
@localhost.setter
def localhost(self,localhost):
self.localhost = localhost
def shcmd(self,cmd,sudo=False):
if sudo:
cmd = "sudo %s" % command
proc = subprocess.Popen(command, shell=True,
stdout = subprocess.PIPE,
stderr = subprocess.PIPE)
stdout, stderr = proc.communicate()
return (stdout, stderr)
def connect(self, username, password, prompt='PEXPECT_OAI'):
self.prompt1 = prompt
self.prompt2 = prompt
self.password = ''
# WE do not store the password when sending commands for secuirity reasons. The password might be accidentally logged in such cases.
#The password is used only to make ssh connections. In case user wants to run programs with sudo, then he/she needs to add following line in /etc/sudoers
# your_user_name ALL=(ALL:ALL) NOPASSWD: ALL
try:
if not username:
username = root
if not password:
password = username
self.oai = pxssh.pxssh()
self.oai.login(self.address,username,password)
self.oai.sendline('PS1='+self.prompt1)
self.oai.PROMPT='PEXPECT_OAI'
# need to look for twice the string of the prompt
self.oai.prompt()
self.oai.prompt()
self.oai.sendline('uptime')
self.oai.prompt()
print self.oai.before
except Exception, e:
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + traceback.format_exc()
print error
sys.exit(1)
def connect2(self, username, password, prompt='$'):
self.prompt1 = prompt
self.prompt2 = prompt
self.password = password
while 1:
try:
if not username:
username = root
if not password:
password = username
self.oai = pexpect.spawn('ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" -o "ConnectionAttempts=1" ' \
+ username + '@' + self.address)
index = self.oai.expect([re.escape(self.prompt1), re.escape(self.prompt2), pexpect.TIMEOUT], timeout=40)
if index == 0 :
return 'Ok'
else :
index = self.oai.expect(['password:', pexpect.TIMEOUT], timeout=40)
if index == 0 :
self.oai.sendline(password)
index = self.oai.expect([re.escape(self.prompt1), re.escape(self.prompt2), pexpect.TIMEOUT], timeout=10)
if index != 0:
print 'ERROR! could not login with SSH.'
print 'Expected ' + self.prompt1 + ', received >>>>' + self.oai.before + '<<<<'
sys.exit(1)
return 'Ok'
except Exception, e:
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + traceback.format_exc()
print error
sys.exit(1)
def connect_localshell(self, prompt='$'):
self.prompt1 = prompt
self.prompt2 = prompt
while 1:
try:
# start a shell and use the current environment
self.oai = pexpect.spawn('bash --norc --noprofile')
index = self.oai.expect([re.escape(self.prompt1), re.escape(self.prompt2), pexpect.TIMEOUT], timeout=40)
if index == 0 :
return 'Ok'
else :
sys.exit(1)
except Exception, e:
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + traceback.format_exc()
print error
sys.exit(1)
def disconnect(self):
print 'disconnecting the ssh connection to ' + self.address + '\n'
self.oai.send('exit')
# self.cancel()
def kill(self, user, pw):
try:
if user == 'root' :
os.system('pkill oaisim oaisim_nos1')
os.system('pkill cc1')
time.sleep(1)
os.system('pkill oaisim oaisim_nos1')
else :
os.system('echo '+pw+' | sudo -S pkill oaisim oaisim_nos1')
os.system('echo '+pw+' | sudo -S pkill cc1')
time.sleep(1)
os.system('echo '+pw+' | sudo -S pkill oaisim oaisim_nos1')
except Exception, e:
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + traceback.format_exc()
print error
sys.exit(1)
def rm_driver(self,oai,user, pw):
try:
if user == 'root' :
#oai.send_nowait('rmmod nasmesh;')
os.system('rmmod nasmesh;')
else :
oai.send_nowait('echo '+pw+ ' | sudo -S rmmod nasmesh;')
#os.system('echo '+pw+ ' | sudo -S rmmod nasmesh;')
except Exception, e:
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + traceback.format_exc()
print error
sys.exit(1)
def driver(self,oai,user,pw):
#pwd = oai.send_recv('pwd')
oai.send('cd $OPENAIR_TARGETS;')
oai.send('cd SIMU/USER;')
try:
if user == 'root' :
oai.send_nowait('insmod ./nasmesh.ko;')
else :
oai.send('echo '+pw+ ' | sudo -S insmod ./nasmesh.ko;')
except Exception, e:
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + traceback.format_exc()
print error
sys.exit(1)
def cleandir (self, logdir,debug) :
for filename in os.listdir(logdir):
filepath = os.path.join(logdir, filename)
if debug == 2 :
print 'logdir is ' + logdir
print 'filepath is ' + filepath
try:
shutil.rmtree(filepath)
except Exception, e:
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + traceback.format_exc()
print error
sys.exit(1)
#print 'Could not remove the filepath'+ filepath + ' with error ' + OSError
def create_dir(self,dirname,debug) :
if not os.path.exists(dirname) :
try:
os.makedirs(dirname,0755)
except OSError:
# There was an error on creation, so make sure we know about it
raise
def cpu_freq(self):
freq=0
proc = subprocess.Popen(["cat","/proc/cpuinfo"],
stdout=subprocess.PIPE)
out, err = proc.communicate()
for line in out.split("\n"):
if "cpu MHz" in line:
freq = float(line.split(":")[1])
break
return freq
......@@ -43,8 +43,8 @@ function test_compile() {
xUnit_start
test_case_name=$1
log_dir=$tdir/log
log_file=$tdir/log/test.$1.txt
log_dir=$tdir/log/$test_case_name
log_file=$log_dir/test.$1.log.txt
compile_prog=$2
compile_args=$3
pre_exec_file=$4
......@@ -57,11 +57,18 @@ function test_compile() {
class=${12}
compile_prog_out=${13}
tags=${14}
build_dir=$tdir/$1/build
exec_file=$build_dir/$6
xmlfile_testcase=$log_dir/test.$1.xml
#build_dir=$tdir/$1/build
#exec_file=$build_dir/$6
#compile_prog_out=`eval "echo $compile_prog_out"`
#echo "compile_prog_out = $compile_prog_out"
read -a compile_prog_out_array <<< "$compile_prog_out"
#Temporary log file where execution log is stored.
temp_exec_log=$log_dir/temp_log.txt
rm -fr $log_dir
mkdir -p $log_dir
......@@ -77,44 +84,78 @@ function test_compile() {
compile_prog_array=()
read -a compile_prog_array <<<"$compile_prog"
tags_array=()
read -a tags_array <<<"$tags"
#tags_array=()
#read -a tags_array <<<"$tags"
pre_compile_prog_array=()
readarray -t pre_compile_prog_array <<< "$pre_compile_prog"
#pre_compile_prog_array=()
#readarray -t pre_compile_prog_array <<< "$pre_compile_prog"
result=1
result_string=""
for (( run_index=1; run_index <= $nruns; run_index++ ))
do
tags_array_index=0
for pre_compile_prog_array_index in "${pre_compile_prog_array[@]}"
do
for compile_prog_array_index in "${compile_prog_array[@]}"
do
echo "Compiling test case $test_case_name.$compile_prog_array_index.${tags_array[$tags_array_index]} Log file = $log_file"
echo "<COMPILATION LOG file=$compile_prog_array_index , Run = $run_index>" >> $log_file
rm -fr $build_dir
mkdir -p $build_dir
cd $build_dir
#tags_array_index=0
#for pre_compile_prog_array_index in "${pre_compile_prog_array[@]}"
#do
#for compile_prog_array_index in "${compile_prog_array[@]}"
#do
echo "Compiling test case $test_case_name.${tags} Log file = $log_file"
date=`date`
echo "<COMPILATION LOG file=$test_case_name.${tags} , Run = $run_index>, Date = $date " >> $log_file
#rm -fr $build_dir
#mkdir -p $build_dir
cd $log_dir
{
eval $pre_compile_prog_array_index
cmake ..
#rm -fv $exec_file
make -j`nproc` $compile_prog_array_index $compile_args
uname -a
compile_log_dir=`eval echo \"$OPENAIR_DIR/cmake_targets/log/\"`
echo "Removing compilation log files in $compile_log_dir"
rm -frv $compile_log_dir
echo "Executing $compile_prog $compile_prog_args ...."
eval $compile_prog $compile_prog_args
echo "Copying compilation log files to test case log directory: $log_dir"
cp -fvr $OPENAIR_DIR/cmake_targets/log/ $log_dir/compile_log
}>> $log_file 2>&1
echo "</COMPILATION LOG>" >> $log_file 2>&1
if [ "$class" == "compilation" ]; then
if [ -s "$compile_prog_array_index" ] || [ -s "$compile_prog_out" ] ; then
echo_success "$test_case_name.$compile_prog_array_index.${tags_array[$tags_array_index]} compiled"
xUnit_success "compilation" "$test_case_name.$compile_prog_array_index.${tags_array[$tags_array_index]}" "PASS" "$run_index"
for compile_prog_out_index in ${compile_prog_out_array[@]}
do
if [ -s "$compile_prog_out_index" ]; then
let "result = result&1"
echo_success "$test_case_name.${tags} RUN = $run_index $compile_prog_out_index = compiled"
else
echo_error "$test_case_name.$exec_prog.${tags_array[$tags_array_index]} compilation failed"
xUnit_fail "compilation" "$test_case_name.$compile_prog_array_index.${tags_array[$tags_array_index]}" "FAIL" "$run_index"
let "result = result&0"
echo_error "$test_case_name.${tags} RUN = $run_index $compile_prog_out_index failed"
fi
done #end of for loop compile_prog_out_index
if [ "$result" == "1" ]; then
result_string=$result_string" Run_$run_index = PASS"
else
result_string=$result_string" Run_$run_index = FAIL"
fi
let "tags_array_index++"
done # End of for loop compile_prog_array
done # End of for loop (pre_compile_prog_array_index)
fi
#let "tags_array_index++"
#done # End of for loop compile_prog_array
#done # End of for loop (pre_compile_prog_array_index)
done #End of for loop (run_index)
#If for for some reason upper for loop does not execute, we fail the test case completely
if [ "$result_string" == "" ]; then
result=0
fi
if [ "$result" == "1" ]; then
echo_success "$test_case_name.${tags} PASSED"
xUnit_success "compilation" "$test_case_name.$tags" "PASS" "$result_string" "$xmlfile_testcase"
else
echo_error "$test_case_name.${tags} FAILED"
xUnit_fail "compilation" "$test_case_name.$tags" "FAIL" "$result_string" "$xmlfile_testcase"
fi
}
......@@ -138,8 +179,8 @@ function test_compile() {
function test_compile_and_run() {
xUnit_start
test_case_name=$1
log_dir=$tdir/log
log_file=$tdir/log/test.$1.txt
log_dir=$tdir/log/$test_case_name
log_file=$log_dir/test.$1.log.txt
compile_prog=$2
compile_args=$3
pre_exec_file=$4
......@@ -155,11 +196,18 @@ function test_compile_and_run() {
tags=${14}
mypassword=${15}
build_dir=$tdir/$1/build
exec_file=$build_dir/$6
#exec_file=$build_dir/$6
xmlfile_testcase=$log_dir/test.$1.xml
#Temporary log file where execution log is stored.
temp_exec_log=$log_dir/temp_log.txt
rm -fr $log_dir
mkdir -p $log_dir
rm -fr $OPENAIR_DIR/cmake_targets/log
echo "" > $temp_exec_log
echo "" > $log_file
#echo "log_dir = $log_dir"
#echo "log_file = $log_file"
#echo "exec_file = $exec_file"
......@@ -169,8 +217,8 @@ function test_compile_and_run() {
#echo "nruns = $nruns"
echo "class = $class"
compile_prog_array=()
read -a compile_prog_array <<<"$compile_prog"
#compile_prog_array=()
#read -a compile_prog_array <<<"$compile_prog"
tags_array=()
read -a tags_array <<<"$tags"
......@@ -178,55 +226,59 @@ function test_compile_and_run() {
main_exec_args_array=()
readarray -t main_exec_args_array <<< "$exec_args"
for search_expr in "${compile_prog_array[@]}"
do
echo "Compiling test case $test_case_name.$search_expr Log file = $log_file"
echo "<COMPILATION LOG file=$search_expr>" >> $log_file
rm -fr $build_dir
mkdir -p $build_dir
#for search_expr in "${compile_prog_array[@]}"
#do
echo "Compiling test case $test_case_name Log file = $log_file"
echo "<COMPILATION LOG file=$log_file>" >> $log_file
cd $build_dir
#rm -fr $build_dir
#mkdir -p $build_dir
cd $log_dir
{
eval $pre_compile_prog
cmake ..
uname -a
#eval $pre_compile_prog
#cmake ..
#rm -fv $exec_file
make -j`nproc` $search_expr $compile_args
echo "Executing $compile_prog $compile_args" >> $log_file
eval "$compile_prog $compile_args"
echo "Copying compilation log files to test case log directory: $log_dir"
cp -fvr $OPENAIR_DIR/cmake_targets/log/ $log_dir/compile_log
}>> $log_file 2>&1
echo "</COMPILATION LOG>" >> $log_file 2>&1
if [ "$class" == "compilation" ]; then
if [ -s "$search_expr" ] ; then
echo_success "$test_case_name $search_expr compiled"
xUnit_success "compilation" "$test_name.$search_expr" "PASS" 1
else
echo_error "$test_case_name $exec_prog compilation failed"
xUnit_fail "compilation" "$test_name.$search_expr" "FAIL" 1
fi
fi
done
#done
#process the test case if it is that of execution
if [ "$class" == "execution" ]; then
tags_array_index=0
for main_exec_args_array_index in "${main_exec_args_array[@]}"
do
global_result=1
result_string=""
for (( run_index=1; run_index <= $nruns; run_index++ ))
do
echo "Executing test case $test_case_name.$main_exec.${tags_array[$tags_array_index]}, Run Index = $run_index, Log file = $log_file"
temp_exec_log=$log_dir/test.$test_case_name.${tags_array[$tags_array_index]}.run_$run_index
echo "" > $temp_exec_log
echo "Executing test case $test_case_name.${tags_array[$tags_array_index]}, Run Index = $run_index, Execution Log file = $temp_exec_log"
echo "-----------------------------------------------------------------------------" >> $log_file 2>&1
echo "<EXECUTION LOG Run = $run_index >" >> $log_file 2>&1
echo "-----------------------------------------------------------------------------" >> $temp_exec_log 2>&1
echo "<EXECUTION LOG Test Case = $test_case_name.${tags_array[$tags_array_index]}, Run = $run_index >" >> $temp_exec_log 2>&1
if [ -n "$pre_exec_file" ]; then
{ eval " echo '$mypassword' |sudo -S -E $pre_exec_file $pre_exec_args " ; }>> $log_file 2>&1
{ echo " Executing $pre_exec_file $pre_exec_args "
eval " echo '$mypassword' |sudo -S -E $pre_exec_file $pre_exec_args " ; }>> $temp_exec_log 2>&1
fi
echo "Executing $exec_file $main_exec_args_array_index "
echo "Executing $exec_file $main_exec_args_array_index " >> $log_file
{ eval "$exec_file $main_exec_args_array_index" ;} > $temp_exec_log 2>&1
echo "Executing $main_exec $main_exec_args_array_index "
echo "Executing $main_exec $main_exec_args_array_index " >> $temp_exec_log
{ uname -a ; eval "$main_exec $main_exec_args_array_index" ;} >> $temp_exec_log 2>&1
echo "</EXECUTION LOG Test Case = $test_case_name.${tags_array[$tags_array_index]}, Run = $run_index >" >> $temp_exec_log 2>&1
cat $temp_exec_log >> $log_file 2>&1
echo "</EXECUTION LOG Test Case = $test_case_name.$main_exec.${tags_array[$tags_array_index]}, Run = $run_index >" >> $log_file 2>&1
result=1
for search_expr in "${search_expr_array[@]}"
......@@ -244,38 +296,49 @@ function test_compile_and_run() {
fi
done
#If we find a negative search result then there is crash of program and test case is failed even if above condition is true
search_result=`grep -iE "$search_expr_negative" $temp_exec_log`
if [ -n "$search_result" ]; then
result=0
fi
let "global_result = global_result & result"
#echo "result = $result"
test_case_result=""
#this is a result of this run
#test_case_result=""
if [ "$result" -eq "0" ]; then
test_case_result="FAIL"
result_string=$result_string" Run_$run_index =FAIL"
echo_error "$test_case_name.${tags_array[$tags_array_index]} RUN = $run_index Result = FAIL"
fi
if [ "$result" -eq "1" ]; then
test_case_result="PASS"
result_string=$result_string" Run_$run_index =PASS"
echo_success "$test_case_name.${tags_array[$tags_array_index]} RUN = $run_index Result = PASS"
fi
#If we find a negative search result then there is crash of program and test case is failed even if above condition is true
search_result=`grep -iE "$search_expr_negative" $temp_exec_log`
if [ -n "$search_result" ]; then
test_case_result="FAIL"
fi
done #End of for loop (nindex)
if [ "$test_case_result" == "FAIL" ]; then
echo_error "execution $test_case_name.$compile_prog.${tags_array[$tags_array_index]} FAIL $run_index"
xUnit_fail "execution" "$test_case_name.$compile_prog.${tags_array[$tags_array_index]}" "FAIL" "$run_index"
fi
echo " Result String = $result_string"
if [ "$test_case_result" == "PASS" ]; then
echo_success "execution $test_case_name.$compile_prog.${tags_array[$tags_array_index]} PASS $run_index"
xUnit_success "execution" "$test_case_name.$compile_prog.${tags_array[$tags_array_index]}" "PASS" "$run_index"
if [ "$result_string" == "" ]; then
echo_error "execution $test_case_name.$compile_prog.${tags_array[$tags_array_index]} Run_Result = \"$result_string\" Result = FAIL"
xUnit_fail "execution" "$test_case_name.${tags_array[$tags_array_index]}" "FAIL" "$result_string" "$xmlfile_testcase"
else
if [ "$global_result" == "0" ]; then
echo_error "execution $test_case_name.${tags_array[$tags_array_index]} Run_Result = \"$result_string\" Result = FAIL"
xUnit_fail "execution" "$test_case_name.${tags_array[$tags_array_index]}" "FAIL" "$result_string" "$xmlfile_testcase"
fi
if [ "$global_result" == "1" ]; then
echo_success "execution $test_case_name.${tags_array[$tags_array_index]} Run_Result = \"$result_string\" Result = PASS "
xUnit_success "execution" "$test_case_name.${tags_array[$tags_array_index]}" "PASS" "$result_string" "$xmlfile_testcase"
fi
fi
done
let "tags_array_index++"
done # End of for loop (nindex)
done
fi
rm -fr $build_dir
}
......@@ -293,16 +356,20 @@ Options
This help
-g | --run-group
Run test cases in a group. For example, ./run_exec_autotests "0101* 010102"
-p
Use password for logging
'
}
function main () {
RUN_GROUP=0
SET_PASSWORD=0
passwd=""
test_case_group=""
test_case_group_array=()
test_case_array=()
echo_info "Note that the user should be sudoer for executing certain commands, for example loading kernel modules"
read -s -p "Enter Password: " mypassword
until [ -z "$1" ]
do
......@@ -312,6 +379,10 @@ until [ -z "$1" ]
test_case_group=$2
echo_info "Will execute test cases only in group $test_case_group"
shift 2;;
-p)
SET_PASSWORD=1
passwd=$2
shift 2;;
-h | --help)
print_help
exit 1;;
......@@ -322,6 +393,22 @@ until [ -z "$1" ]
esac
done
if [ "$SET_PASSWORD" == "1" ]; then
mypassword=$passwd
else
read -s -p "Enter Password: " mypassword
fi
tmpfile=`mktemp`
echo \'$passwd\' | sudo echo $HOME >& $tmpfile
tstsudo=`cat $tmpfile`
if [ "$tstsudo" != "$HOME" ]; then
echo "User might not have sudo privileges. Exiting"
echo "tstsudo = $tstsudo"
exit
fi
echo "tstsudo = $tstsudo"
rm -fr $tmpfile
xml_conf="$OPENAIR_DIR/cmake_targets/autotests/test_case_list.xml"
......@@ -376,6 +463,8 @@ for search_expr in "${test_case_array[@]}"
echo "Description = $desc"
echo "pre_compile_prog = $pre_compile_prog"
echo "compile_prog = $compile_prog"
echo "compile_prog_args = $compile_prog_args"
echo "compile_prog_out = $compile_prog_out"
echo "pre_exec = $pre_exec"
echo "pre_exec_args = $pre_exec_args"
echo "main_exec = $main_exec"
......@@ -385,6 +474,7 @@ for search_expr in "${test_case_array[@]}"
echo "nruns = $nruns"
#eval $pre_exec
compile_prog_out=`eval echo \"$compile_prog_out\"`
search_array_true=()
......@@ -416,6 +506,8 @@ for search_expr in "${test_case_array[@]}"
}
uname -a
main "$@"
xUnit_write "$results_file"
......
......@@ -49,6 +49,8 @@ import math #from time import clock
import xml.etree.ElementTree as ET
import re
import numpy as np
import log
import case01
import case02
......@@ -59,15 +61,100 @@ import case05
from openair import *
import paramiko
import subprocess
import commands
sys.path.append('/opt/ssh')
import ssh
from ssh import SSHSession
def write_file(filename, string, mode="w"):
text_file = open(filename, mode)
text_file.write(string)
text_file.close()
#$1 name of file (assuming created with iperf -s -u ....
#$2 minimum throughput
#$3 maximum throughput
#$4 average throughput
#$5 minimum duration of throughput
#The throughput values found in file must be higher than values from from 2,3,4,5
#The function returns True if throughput conditions are saisfied else it returns fails
def tput_test(filename, min_tput, max_tput, average, min_duration):
if os.path.exists(filename):
with open (filename, "r") as myfile:
data=myfile.read()
p=re.compile('(\d*.\d*) Mbits/sec')
array=p.findall(data)
array = [ float(x) for x in array ]
duration = array.__len__()
if duration !=0:
min_list = min(array)
max_list = max(array)
average_list = np.mean(array)
else:
min_list = 0
max_list = 0
average_list=0
if (min_list >= min_tput and max_list >= max_tput and average_list >= average and duration >= min_duration):
return True
else:
return False
else:
return False
def try_convert_to_float(string, fail=None):
try:
return float(string)
except Exception:
return fail;
def tput_test_search_expr (search_expr, logfile_traffic):
result=0
if search_expr !='':
if search_expr.find('throughput_test')!= -1 :
p= re.compile('min\s*=\s*(\d*.\d*)\s*Mbits/sec')
min_tput=p.findall(search_expr)
if min_tput.__len__()==1:
min_tput = min_tput[0]
else:
min_tput = None
p= re.compile('max\s*=\s*(\d*.\d*)\s*Mbits/sec')
max_tput=p.findall(search_expr)
if max_tput.__len__()==1:
max_tput = max_tput[0]
else:
max_tput = None
p= re.compile('average\s*=\s*(\d*.\d*)\s*Mbits/sec')
avg_tput=p.findall(search_expr)
if avg_tput.__len__()==1:
avg_tput=avg_tput[0]
else:
avg_tput = None
p= re.compile('duration\s*=\s*(\d*.\d*)\s*s')
duration=p.findall(search_expr)
if duration.__len__()==1:
duration = duration[0]
else:
duration = None
min_tput = try_convert_to_float(min_tput)
max_tput = try_convert_to_float(max_tput)
avg_tput = try_convert_to_float(avg_tput)
duration = try_convert_to_float(duration)
if (min_tput != None and max_tput != None and avg_tput != None and duration != None ):
result = tput_test(logfile_traffic, min_tput, max_tput, avg_tput, duration)
return result
def sftp_module (username, password, hostname, ports, paramList,logfile):
#localD = localfile
......@@ -107,6 +194,7 @@ def sftp_module (username, password, hostname, ports, paramList,logfile):
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + '\n username = ' + username + '\n hostname = ' + hostname + '\n localfile = ' + localD + '\n remotefile = ' + remoteD + '\n operation = ' + operation + '\nlogfile = ' + logfile + '\n ports = ' + str(ports) + '\n'
error = error + traceback.format_exc()
print error
sftp.close()
transport.close()
......@@ -145,10 +233,11 @@ def finalize_deploy_script (timeout_cmd, terminate_missing_procs='True'):
sleep $wakeup_interval
done
echo "Final time step (Duration of test case) = $step "
date
"""
else:
#We do not terminate the script if one of the processes has existed prematurely
cmd = cmd + 'sleep ' + str(timeout_cmd) + '\n'
cmd = cmd + 'sleep ' + str(timeout_cmd) + ' ; date \n'
return cmd
......@@ -195,66 +284,173 @@ class myThread (threading.Thread):
class oaiThread (threading.Thread):
def __init__(self, threadID, name, oai, cmd, sudo, timeout):
def __init__(self, threadID, threadname, machine, username, password, cmd, sudo, timeout):
threading.Thread.__init__(self)
self.threadID = threadID
self.name = name
#self.counter = counter
self.oai = oai
self.threadname = threadname
self.machine = machine
self.username = username
self.password = password
self.cmd = cmd
self.sudo = sudo
self.timeout = timeout
self.machineName = machineName
def run(self):
print "Starting " + self.name
result = self.oai.send_recv(self.cmd, self.sudo, self.timeout)
try:
oai = openair('localdomain',self.machine)
oai.connect(user, self.password)
print "Starting " + self.threadname + " on machine " + self.machine
result = oai.send_recv(self.cmd, self.sudo, self.timeout)
print "result = " + result
print "Exiting " + self.name
print "Exiting " + self.threadname
oai.disconnect()
except Exception, e:
error=''
error = error + ' In class oaiThread, function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + '\n threadID = ' + str(self.threadID) + '\n threadname = ' + self.threadname + '\n timeout = ' + self.timeout + '\n machine = ' + self.machine + '\n cmd = ' + self.cmd + '\n timeout = ' + str(self.timeout) + '\n'
error = error + traceback.format_exc()
print error
#This class runs test cases with class oaisim_noS1, compilatation
class testCaseThread_generic(threading.thread):
def __init__(self, threadID, name, oai, machine, logdirOAI5GRepo, oai5GRepoDirRemote, testcasename,oldprogramList, CleanupAluLteBox, username, password, timeout):
#This class runs test cases with class execution, compilatation
class testCaseThread_generic (threading.Thread):
def __init__(self, threadID, name, machine, logdirOAI5GRepo, testcasename,oldprogramList, CleanupAluLteBox, password, timeout):
threading.Thread.__init__(self)
self.threaID = threadID
self.threadID = threadID
self.name = name
self.oai = oai
self.testcasename = testcasename
self.timeout = timeout
self.machine = machine
self.oai5GRepoDirRemote = oai5GRepoDirRemote
self.logdirOAI5GRepo = logdirOAI5GRepo
self.username = username
self.password = password
self.oldprogramList = oldprogramList
self.CleanupAluLteBox = CleanupAluLteBox
self.password=password
def run(self):
try:
mypassword=''
#addsudo = 'echo \'' + mypassword + '\' | sudo -S -E '
addpass = 'echo \'' + mypassword + '\' | '
user = getpass.getuser()
print "Starting test case : " + self.testcasename + " On machine " + machineName
cleanOldPrograms(oai, oldprogramList, CleanUpAluLteBox)
logdir_local_testcase = logdirOAI5GRepo+'/cmake_targets/autotests/log/'+ testcasename
logdir_local_base = logdirOAI5GRepo+'/cmake_targets/autotests/log/'
logdir_remote_testcase = oai5GRepoDirRemote + '/cmake_targets/autotests/log' + self.testcasename
os.removedirs(logdir_testcase)
os.mkdir (logdir_testcase)
cmd = "( cd " + self.oai5GRepoDirRemote + " \n "
print "Starting test case : " + self.testcasename + " On machine " + self.machine + " timeout = " + str(self.timeout)
oai = openair('localdomain',self.machine)
oai.connect(user, self.password)
cleanOldPrograms(oai, self.oldprogramList, self.CleanupAluLteBox)
logdir_local = os.environ.get('OPENAIR_DIR')
logdir_local_testcase = logdir_local +'/cmake_targets/autotests/log/'+ self.testcasename
logdir_local_base = logdir_local +'/cmake_targets/autotests/log/'
logdir_remote_testcase = self.logdirOAI5GRepo + '/cmake_targets/autotests/log/' + self.testcasename
logdir_remote = self.logdirOAI5GRepo + '/cmake_targets/autotests/log/'
logfile_task_testcasename = logdir_local_testcase + '/test_task' + '_' + self.testcasename + '_.log'
logfile_task_testcasename_out = logdir_remote + '/test_task_out' + '_' + self.testcasename + '_.log'
#print "logdir_local_testcase = " + logdir_local_testcase
#print "logdir_remote_testcase = " + logdir_remote_testcase
#if os.path.exists(logdir_local_testcase) == True :
# os.removedirs(logdir_local_testcase)
#os.mkdir(logdir_local_testcase)
os.system("rm -fr " + logdir_local_testcase )
os.system("mkdir -p " + logdir_local_testcase)
cmd = "mkdir -p " + logdir_remote_testcase
res = oai.send_recv(cmd, False, self.timeout)
#print "res = " + res
cmd = "( cd " + self.logdirOAI5GRepo + " \n "
cmd = cmd + "source oaienv \n"
cmd = cmd + "python run_test_case_generic -d " + self.oai5GRepoDirRemote + " -g " + "\"" + self.testcasename + "\""
cmd = cmd + " ) "
#Now we copy all the remote
ssh = SSHSession(self.machine , username=username, key_file=None, passsword=password)
cmd = cmd + "$OPENAIR_DIR/cmake_targets/autotests/run_exec_autotests.bash --run-group \"" + self.testcasename + "\" -p \'\'"
cmd = cmd + " ) >& " + logfile_task_testcasename_out + " ; " + "mkdir -p " + logdir_remote_testcase + "; mv " + logfile_task_testcasename_out + " " +logdir_remote_testcase
#print "cmd = " + cmd
res = oai.send_recv(cmd, False, self.timeout)
#print "res = " + res
#print "ThreadID = " + str(self.threadID) + "ThreadName: " + self.name + " testcasename: " + self.testcasename + "Execution Result = " + res
write_file(logfile_task_testcasename, cmd, mode="w")
#Now we copy all the remote files
ssh = SSHSession(self.machine , username=user, key_file=None, password=self.password)
ssh.get_all(logdir_remote_testcase , logdir_local_base)
print "Finishing test case : " + self.testcasename + " On machine " + machineName
print "Finishing test case : " + self.testcasename + " On machine " + self.machine
cleanOldPrograms(oai, self.oldprogramList, self.CleanupAluLteBox)
#oai.kill(user,mypassword)
oai.disconnect()
except Exception, e:
error=''
error = error + ' In Class = testCaseThread_generic, function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + '\n threadID = ' + str(self.threadID) + '\n threadName = ' + self.name + '\n testcasename = ' + self.testcasename + '\n machine = ' + self.machine + '\n logdirOAI5GRepo = ' + self.logdirOAI5GRepo + '\n' + '\n timeout = ' + str(timeout)
error = error + traceback.format_exc()
print error
sys.exit()
def addsudo (cmd, password=""):
cmd = 'echo \'' + password + '\' | sudo -S -E bash -c \' ' + cmd + '\' '
return cmd
def handle_testcaseclass_generic (testcasename, threadListGeneric, oldprogramList, logdirOAI5GRepo, MachineList, password, CleanupAluLteBox,timeout):
try:
mypassword=password
MachineListFree=[]
threadListNew=[]
while MachineListFree.__len__() == 0 :
MachineListBusy=[]
MachineListFree=[]
threadListNew=[]
#first we need to find the list of free machines that we could run our test case
if threadListGeneric.__len__() ==0 :
#This means no thread is started yet
MachineListFree = MachineList[:]
else :
for param in threadListGeneric :
thread_id = param["thread_id"]
machine = param["Machine"]
testcasenameold = param["testcasename"]
thread_id.join(1)
if thread_id.isAlive() == True:
threadListNew.append(param)
print "thread_id is alive: testcasename: " + testcasenameold + " on machine "+ machine
if machine not in MachineListBusy:
MachineListBusy.append(machine)
else :
print "thread_id is finished: testcasename: " + testcasenameold + " on machine " + machine
#threadListGeneric.remove(param)
#if machine not in MachineListFree:
# MachineListFree.append(machine)
#Now we check if there is at least one free machine
MachineListFree = MachineList[:]
for machine in MachineListBusy:
if machine in MachineListFree:
MachineListFree.remove(machine)
print "MachineListFree = " + ','.join(MachineListFree)
print "MachineListBusy = " + ','.join(MachineListBusy)
print "MachineList = " + ','.join(MachineList)
machine = MachineListFree[0]
thread = testCaseThread_generic(1,"Generic Thread_"+testcasename+"_"+ "machine_", machine, logdirOAI5GRepo, testcasename, oldprogramList, CleanupAluLteBox, password, timeout)
param={"thread_id":thread, "Machine":machine, "testcasename":testcasename}
thread.start()
threadListNew.append(param)
return threadListNew
except Exception, e:
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + '\n testcasename = ' + testcasename + '\n logdirOAI5GRepo = ' + logdirOAI5GRepo + '\n MachineList = ' + ','.join(MachineList) + '\n timeout = ' + str(timeout) + '\n'
error = error + traceback.format_exc()
print error
sys.exit(1)
#Blocking wait for all threads related to generic testcase execution, class (compilation and execution)
def wait_testcaseclass_generic_threads(threadListGeneric, timeout = 1):
for param in threadListGeneric:
thread_id = param["thread_id"]
machine = param["Machine"]
testcasenameold = param["testcasename"]
thread_id.join(timeout)
if thread_id.isAlive() == True:
print "thread_id on machine: " + machine + " is still alive: testcasename: " + testcasenameold
print " Exiting now..."
sys.exit(1)
else:
print "thread_id on machine: " + machine + " is stopped: testcasename: " + testcasenameold
threadListGeneric.remove(param)
return threadListGeneric
#Function to handle test case class : lte-softmodem
def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOAI5GRepo , logdirOpenaircnRepo, MachineList, password, CleanUpAluLteBox):
def handle_testcaseclass_softmodem (testcase, oldprogramList, logdirOAI5GRepo , logdirOpenaircnRepo, MachineList, password, CleanUpAluLteBox):
#We ignore the password sent to this function for secuirity reasons for password present in log files
#It is recommended to add a line in /etc/sudoers that looks something like below. The line below will run sudo without password prompt
# your_user_name ALL=(ALL:ALL) NOPASSWD: ALL
......@@ -263,13 +459,14 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
addpass = 'echo \'' + mypassword + '\' | '
user = getpass.getuser()
testcasename = testcase.get('id')
testcaseclass = testcase.findtext('class',default='')
timeout_cmd = testcase.findtext('TimeOut_cmd',default='')
timeout_cmd = int(float(timeout_cmd))
#Timeout_thread is more than that of cmd to have room for compilation time, etc
timeout_thread = timeout_cmd + 300
nruns = testcase.findtext('nruns',default='')
nruns = int(float(nruns))
tags = testcase.findtext('tags',default='')
eNBMachine = testcase.findtext('eNB',default='')
eNB_config_file = testcase.findtext('eNB_config_file',default='')
eNB_compile_prog = testcase.findtext('eNB_compile_prog',default='')
......@@ -281,6 +478,7 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
eNB_traffic_exec = testcase.findtext('eNB_traffic_exec',default='')
eNB_traffic_exec_args = testcase.findtext('eNB_traffic_exec_args',default='')
eNB_terminate_missing_procs = testcase.findtext('eNB_terminate_missing_procs',default='True')
eNB_search_expr_true = testcase.findtext('eNB_search_expr_true','')
UEMachine = testcase.findtext('UE',default='')
UE_config_file = testcase.findtext('UE_config_file',default='')
......@@ -293,6 +491,7 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
UE_traffic_exec = testcase.findtext('UE_traffic_exec',default='')
UE_traffic_exec_args = testcase.findtext('UE_traffic_exec_args',default='')
UE_terminate_missing_procs = testcase.findtext('UE_terminate_missing_procs',default='True')
UE_search_expr_true = testcase.findtext('UE_search_expr_true','')
EPCMachine = testcase.findtext('EPC',default='')
EPC_config_file = testcase.findtext('EPC_config_file',default='')
......@@ -310,19 +509,18 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
EPC_traffic_exec = testcase.findtext('EPC_traffic_exec',default='')
EPC_traffic_exec_args = testcase.findtext('EPC_traffic_exec_args',default='')
EPC_terminate_missing_procs = testcase.findtext('EPC_terminate_missing_procs',default='True')
EPC_search_expr_true = testcase.findtext('EPC_search_expr_true','')
index_eNBMachine = MachineList.index(eNBMachine)
index_UEMachine = MachineList.index(UEMachine)
index_EPCMachine = MachineList.index(EPCMachine)
oai_eNB = oai_list[index_eNBMachine]
oai_UE = oai_list[index_UEMachine]
#We need to create two ssh sessions to avoid race conditions
if index_eNBMachine == index_EPCMachine:
oai_eNB = openair('localdomain', eNBMachine)
oai_eNB.connect(user, password)
oai_UE = openair('localdomain', UEMachine)
oai_UE.connect(user, password)
oai_EPC = openair('localdomain', EPCMachine)
oai_EPC.connect(user,password)
else:
oai_EPC = oai_list[index_EPCMachine]
oai_EPC.connect(user, password)
cleanOldPrograms(oai_eNB, oldprogramList, CleanUpAluLteBox)
cleanOldPrograms(oai_UE, oldprogramList, CleanUpAluLteBox)
cleanOldPrograms(oai_EPC, oldprogramList, CleanUpAluLteBox)
......@@ -347,8 +545,12 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
#update_config_file(oai_eNB, eNB_config_file, logdirOAI5GRepo)
#update_config_file(oai_UE, UE_config_file, logdirOAI5GRepo)
#update_config_file(oai_EPC, EPC_config_file, logdirOpenaircnRepo)
test_result=1
test_result_string=''
start_time=time.time()
for run in range(0,nruns):
run_result=1
run_result_string=''
logdir_eNB = logdirOAI5GRepo+'/cmake_targets/autotests/log/'+ testcasename + '/run_' + str(run)
logdir_UE = logdirOAI5GRepo+'/cmake_targets/autotests/log/'+ testcasename + '/run_' + str(run)
logdir_EPC = logdirOpenaircnRepo+'/TEST/autotests/log/'+ testcasename + '/run_' + str(run)
......@@ -367,14 +569,24 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
logfile_exec_eNB = logdir_eNB + '/eNB_exec' + '_' + str(run) + '_.log'
logfile_pre_exec_eNB = logdir_eNB + '/eNB_pre_exec' + '_' + str(run) + '_.log'
logfile_traffic_eNB = logdir_eNB + '/eNB_traffic' + '_' + str(run) + '_.log'
logfile_task_eNB_compile_out = logdir_eNB + '/eNB_task_compile_out' + '_' + str(run) + '_.log'
logfile_task_eNB_compile = logdir_local_testcase + '/eNB_task_compile' + '_' + str(run) + '_.log'
logfile_task_eNB_out = logdir_eNB + '/eNB_task_out' + '_' + str(run) + '_.log'
logfile_task_eNB = logdir_local_testcase + '/eNB_task' + '_' + str(run) + '_.log'
task_eNB = ' ( \n'
task_eNB = task_eNB + 'cd ' + logdirOAI5GRepo + ' ; source oaienv ; source cmake_targets/tools/build_helper \n'
task_eNB = task_eNB + 'env |grep OPENAIR \n'
task_eNB = task_eNB + update_config_file(oai_eNB, eNB_config_file, logdirOAI5GRepo, '$OPENAIR_DIR/cmake_targets/autotests/tools/search_repl.py') + '\n'
task_eNB_compile = ' ( uname -a ; date \n'
task_eNB_compile = task_eNB_compile + 'cd ' + logdirOAI5GRepo + ' ; source oaienv ; source cmake_targets/tools/build_helper \n'
task_eNB_compile = task_eNB_compile + 'env |grep OPENAIR \n'
task_eNB_compile = task_eNB_compile + update_config_file(oai_eNB, eNB_config_file, logdirOAI5GRepo, '$OPENAIR_DIR/cmake_targets/autotests/tools/search_repl.py') + '\n'
if eNB_compile_prog != "":
task_eNB = task_eNB + ' ( ' + eNB_compile_prog + ' '+ eNB_compile_prog_args + ' ) > ' + logfile_compile_eNB + ' 2>&1 \n'
task_eNB_compile = task_eNB_compile + ' ( ' + eNB_compile_prog + ' '+ eNB_compile_prog_args + ' ) > ' + logfile_compile_eNB + ' 2>&1 \n'
task_eNB_compile = task_eNB_compile + ' date ) > ' + logfile_task_eNB_compile_out + ' 2>&1 '
write_file(logfile_task_eNB_compile, task_eNB_compile, mode="w")
task_eNB = ' ( uname -a ; date \n'
task_eNB = task_eNB + 'cd ' + logdirOAI5GRepo + ' ; source oaienv ; source cmake_targets/tools/build_helper \n'
task_eNB = task_eNB + 'env |grep OPENAIR \n' + 'array_exec_pid=() \n'
if eNB_pre_exec != "":
task_eNB = task_eNB + ' ( ' + eNB_pre_exec + ' '+ eNB_pre_exec_args + ' ) > ' + logfile_pre_exec_eNB + ' 2>&1 \n'
if eNB_main_exec != "":
......@@ -399,15 +611,27 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
logfile_traffic_UE = logdir_UE + '/UE_traffic' + '_' + str(run) + '_.log'
logfile_task_UE_out = logdir_UE + '/UE_task_out' + '_' + str(run) + '_.log'
logfile_task_UE = logdir_local_testcase + '/UE_task' + '_' + str(run) + '_.log'
task_UE = ' ( \n'
logfile_task_UE_compile_out = logdir_UE + '/UE_task_compile_out' + '_' + str(run) + '_.log'
logfile_task_UE_compile = logdir_local_testcase + '/UE_task_compile' + '_' + str(run) + '_.log'
task_UE_compile = ' ( uname -a ; date \n'
task_UE_compile = task_UE_compile + 'array_exec_pid=()' + '\n'
task_UE_compile = task_UE_compile + 'cd ' + logdirOAI5GRepo + '\n'
task_UE_compile = task_UE_compile + 'source oaienv \n'
task_UE_compile = task_UE_compile + 'source cmake_targets/tools/build_helper \n'
task_UE_compile = task_UE_compile + 'env |grep OPENAIR \n'
task_UE_compile = task_UE_compile + update_config_file(oai_UE, UE_config_file, logdirOAI5GRepo, '$OPENAIR_DIR/cmake_targets/autotests/tools/search_repl.py') + '\n'
if UE_compile_prog != "":
task_UE_compile = task_UE_compile + ' ( ' + UE_compile_prog + ' '+ UE_compile_prog_args + ' ) > ' + logfile_compile_UE + ' 2>&1 \n'
task_UE_compile = task_UE_compile + ' ) > ' + logfile_task_UE_compile_out + ' 2>&1 '
write_file(logfile_task_UE_compile, task_UE_compile, mode="w")
task_UE = ' ( uname -a ; date \n'
task_UE = task_UE + 'array_exec_pid=()' + '\n'
task_UE = task_UE + 'cd ' + logdirOAI5GRepo + '\n'
task_UE = task_UE + 'source oaienv \n'
task_UE = task_UE + 'source cmake_targets/tools/build_helper \n'
task_UE = task_UE + 'env |grep OPENAIR \n'
task_UE = task_UE + update_config_file(oai_UE, UE_config_file, logdirOAI5GRepo, '$OPENAIR_DIR/cmake_targets/autotests/tools/search_repl.py') + '\n'
if UE_compile_prog != "":
task_UE = task_UE + ' ( ' + UE_compile_prog + ' '+ UE_compile_prog_args + ' ) > ' + logfile_compile_UE + ' 2>&1 \n'
if UE_pre_exec != "":
task_UE = task_UE + ' ( ' + UE_pre_exec + ' '+ UE_pre_exec_args + ' ) > ' + logfile_pre_exec_UE + ' 2>&1 \n'
if UE_main_exec != "":
......@@ -434,25 +658,35 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
logfile_traffic_EPC = logdir_EPC + '/EPC_traffic' + '_' + str(run) + '_.log'
logfile_task_EPC_out = logdir_EPC + '/EPC_task_out' + '_' + str(run) + '_.log'
logfile_task_EPC = logdir_local_testcase + '/EPC_task' + '_' + str(run) + '_.log'
task_EPC = ' ( \n'
logfile_task_EPC_compile_out = logdir_EPC + '/EPC_task_compile_out' + '_' + str(run) + '_.log'
logfile_task_EPC_compile = logdir_local_testcase + '/EPC_task_compile' + '_' + str(run) + '_.log'
task_EPC_compile = ' ( uname -a ; date \n'
task_EPC_compile = task_EPC_compile + 'array_exec_pid=()' + '\n'
task_EPC_compile = task_EPC_compile + 'cd ' + logdirOpenaircnRepo + '\n'
task_EPC_compile = task_EPC_compile + update_config_file(oai_EPC, EPC_config_file, logdirOpenaircnRepo, logdirOpenaircnRepo+'/TEST/autotests/tools/search_repl.py') + '\n'
task_EPC_compile = task_EPC_compile + 'source BUILD/TOOLS/build_helper \n'
if EPC_compile_prog != "":
task_EPC_compile = task_EPC_compile + '(' + EPC_compile_prog + ' ' + EPC_compile_prog_args + ' ) > ' + logfile_compile_EPC + ' 2>&1 \n'
if HSS_compile_prog != "":
task_EPC_compile = task_EPC_compile + '(' + HSS_compile_prog + ' ' + HSS_compile_prog_args + ' ) > ' + logfile_compile_HSS + ' 2>&1 \n'
task_EPC_compile = task_EPC_compile + ' ) > ' + logfile_task_EPC_compile_out + ' 2>&1 '
write_file(logfile_task_EPC_compile, task_EPC_compile, mode="w")
task_EPC = ' ( uname -a ; date \n'
task_EPC = task_EPC + 'array_exec_pid=()' + '\n'
task_EPC = task_EPC + 'cd ' + logdirOpenaircnRepo + '\n'
task_EPC = task_EPC + update_config_file(oai_EPC, EPC_config_file, logdirOpenaircnRepo, logdirOpenaircnRepo+'/TEST/autotests/tools/search_repl.py') + '\n'
task_EPC = task_EPC + 'source BUILD/TOOLS/build_helper \n'
if EPC_compile_prog != "":
task_EPC = task_EPC + '(' + EPC_compile_prog + ' ' + EPC_compile_prog_args + ' ) > ' + logfile_compile_EPC + ' 2>&1 \n'
if HSS_compile_prog != "":
task_EPC = task_EPC + '(' + HSS_compile_prog + ' ' + HSS_compile_prog_args + ' ) > ' + logfile_compile_HSS + ' 2>&1 \n'
if EPC_pre_exec != "":
task_EPC = task_EPC + ' ( ' + EPC_pre_exec + ' '+ EPC_pre_exec_args + ' ) > ' + logfile_pre_exec_EPC + ' 2>&1 \n'
if EPC_main_exec != "":
task_EPC = task_EPC + '(' + addsudo (EPC_main_exec + ' ' + EPC_main_exec_args, mypassword) + ' ) > ' + logfile_exec_EPC + ' 2>&1 & \n'
task_EPC = task_EPC + 'array_exec_pid+=($!) \n'
task_EPC = task_EPC + 'echo EPC_main_exec PID = $! \n'
if HSS_main_exec != "":
task_EPC = task_EPC + '(' + addsudo (HSS_main_exec + ' ' + HSS_main_exec_args, mypassword) + ' ) > ' + logfile_exec_HSS + ' 2>&1 & \n'
task_EPC = task_EPC + 'array_exec_pid+=($!) \n'
task_EPC = task_EPC + 'echo HSS_main_exec PID = $! \n'
if EPC_main_exec != "":
task_EPC = task_EPC + '(' + addsudo (EPC_main_exec + ' ' + EPC_main_exec_args, mypassword) + ' ) > ' + logfile_exec_EPC + ' 2>&1 & \n'
task_EPC = task_EPC + 'array_exec_pid+=($!) \n'
task_EPC = task_EPC + 'echo EPC_main_exec PID = $! \n'
if EPC_traffic_exec != "":
task_EPC = task_EPC + '(' + EPC_traffic_exec + ' ' + EPC_traffic_exec_args + ' ) > ' + logfile_traffic_EPC + ' 2>&1 & \n'
task_EPC = task_EPC + 'array_exec_pid+=($!) \n'
......@@ -464,9 +698,26 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
task_EPC = task_EPC + ' ) > ' + logfile_task_EPC_out + ' 2>&1 '
write_file(logfile_task_EPC, task_EPC, mode="w")
thread_EPC = oaiThread(1, "EPC_thread", oai_EPC , task_EPC, False, timeout_thread)
thread_eNB = oaiThread(2, "eNB_thread", oai_eNB , task_eNB, False, timeout_thread)
thread_UE = oaiThread(3, "UE_thread", oai_UE , task_UE, False, timeout_thread)
#first we compile all the programs
thread_EPC = oaiThread(1, "EPC_thread", EPCMachine, user, password , task_EPC_compile, False, timeout_thread)
thread_eNB = oaiThread(2, "eNB_thread", eNBMachine, user, password , task_eNB_compile, False, timeout_thread)
thread_UE = oaiThread(3, "UE_thread", UEMachine, user, password , task_UE_compile, False, timeout_thread)
threads=[]
threads.append(thread_eNB)
threads.append(thread_UE)
threads.append(thread_EPC)
# Start new Threads
thread_eNB.start()
thread_UE.start()
thread_EPC.start()
#Wait for all the compile threads to complete
for t in threads:
t.join()
#Now we execute all the threads
thread_EPC = oaiThread(1, "EPC_thread", EPCMachine, user, password , task_EPC, False, timeout_thread)
thread_eNB = oaiThread(2, "eNB_thread", eNBMachine, user, password , task_eNB, False, timeout_thread)
thread_UE = oaiThread(3, "UE_thread", UEMachine, user, password , task_UE, False, timeout_thread)
threads=[]
threads.append(thread_eNB)
......@@ -487,102 +738,51 @@ def handle_testcaseclass_softmodem (testcase, oldprogramList, oai_list, logdirOA
cleanOldPrograms(oai_UE, oldprogramList, CleanUpAluLteBox)
cleanOldPrograms(oai_EPC, oldprogramList, CleanUpAluLteBox)
localfile = logdir_local_testcase + '/eNB_compile' + '_' + str(run) + '_.log'
remotefile = logdir_eNB + '/eNB_compile' + '_' + str(run) + '_.log'
sftp_log = os.path.expandvars(logdir_local_testcase + '/sftp_module.log')
ports = 22
paramList = []
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, eNBMachine, ports, localfile, remotefile, sftp_log, "get")
localfile = logdir_local_testcase + '/eNB_exec' + '_' + str(run) + '_.log'
remotefile = logdir_eNB + '/eNB_exec' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, eNBMachine, ports, localfile, remotefile, sftp_log, "get")
localfile = logdir_local_testcase + '/eNB_pre_exec' + '_' + str(run) + '_.log'
remotefile = logdir_eNB + '/eNB_pre_exec' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, eNBMachine, ports, localfile, remotefile, sftp_log, "get")
localfile = logdir_local_testcase + '/eNB_traffic' + '_' + str(run) + '_.log'
remotefile = logdir_eNB + '/eNB_traffic' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, eNBMachine, ports, localfile, remotefile, sftp_log, "get")
localfile = logdir_local_testcase + '/eNB_task_out' + '_' + str(run) + '_.log'
remotefile = logdir_eNB + '/eNB_task_out' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
localfile = logdir_local_testcase + '/test_case_list.xml'
remotefile = logdirOAI5GRepo+'/cmake_targets/autotests/test_case_list.xml'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
sftp_module (user, password, eNBMachine, ports, paramList, sftp_log)
paramList=[]
localfile = logdir_local_testcase + '/UE_compile' + '_' + str(run) + '_.log'
remotefile = logdir_UE + '/UE_compile' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, UEMachine, ports, localfile, remotefile, sftp_log, "get")
localfile = logdir_local_testcase + '/UE_exec' + '_' + str(run) + '_.log'
remotefile = logdir_UE + '/UE_exec' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, UEMachine, ports, localfile, remotefile, sftp_log, "get")
localfile = logdir_local_testcase + '/UE_pre_exec' + '_' + str(run) + '_.log'
remotefile = logdir_UE + '/UE_pre_exec' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, UEMachine, ports, localfile, remotefile, sftp_log, "get")
localfile = logdir_local_testcase + '/UE_traffic' + '_' + str(run) + '_.log'
remotefile = logdir_UE + '/UE_traffic' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, UEMachine, ports, localfile, remotefile, sftp_log, "get")
localfile = logdir_local_testcase + '/UE_task_out' + '_' + str(run) + '_.log'
remotefile = logdir_UE + '/UE_task_out' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
sftp_module (user, password, UEMachine, ports, paramList, sftp_log)
paramList=[]
localfile = logdir_local_testcase + '/EPC_compile' + '_' + str(run) + '_.log'
remotefile = logdir_EPC + '/EPC_compile' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, EPCMachine, ports, localfile, remotefile, sftp_log, "get")
print "Copying files from EPCMachine : " + EPCMachine + "logdir_EPC = " + logdir_EPC
ssh = SSHSession(EPCMachine , username=user, key_file=None, password=password)
ssh.get_all(logdir_EPC , logdir_local + '/cmake_targets/autotests/log/'+ testcasename)
localfile = logdir_local_testcase + '/EPC_exec' + '_' + str(run) + '_.log'
remotefile = logdir_EPC + '/EPC_exec' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, EPCMachine, ports, localfile, remotefile, sftp_log, "get")
print "Copying files from eNBMachine " + eNBMachine + "logdir_eNB = " + logdir_eNB
ssh = SSHSession(eNBMachine , username=user, key_file=None, password=password)
ssh.get_all(logdir_eNB, logdir_local + '/cmake_targets/autotests/log/'+ testcasename)
localfile = logdir_local_testcase + '/HSS_compile' + '_' + str(run) + '_.log'
remotefile = logdir_EPC + '/HSS_compile' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, EPCMachine, ports, localfile, remotefile, sftp_log, "get")
print "Copying files from UEMachine : " + UEMachine + "logdir_UE = " + logdir_UE
ssh = SSHSession(UEMachine , username=user, key_file=None, password=password)
ssh.get_all(logdir_UE , logdir_local + '/cmake_targets/autotests/log/'+ testcasename)
localfile = logdir_local_testcase + '/HSS_exec' + '_' + str(run) + '_.log'
remotefile = logdir_EPC + '/HSS_exec' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, EPCMachine, ports, localfile, remotefile, sftp_log, "get")
#Currently we only perform throughput tests
result = tput_test_search_expr(eNB_search_expr_true, logfile_traffic_eNB)
run_result=run_result&result
result = tput_test_search_expr(EPC_search_expr_true, logfile_traffic_EPC)
run_result=run_result&result
result = tput_test_search_expr(UE_search_expr_true, logfile_traffic_UE)
run_result=run_result&result
localfile = logdir_local_testcase + '/EPC_pre_exec' + '_' + str(run) + '_.log'
remotefile = logdir_EPC + '/EPC_pre_exec' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, EPCMachine, ports, localfile, remotefile, sftp_log, "get")
if run_result == 1:
run_result_string = 'RUN_'+str(run) + ' = PASS'
else:
run_result_string = 'RUN_'+str(run) + ' = FAIL'
localfile = logdir_local_testcase + '/EPC_traffic' + '_' + str(run) + '_.log'
remotefile = logdir_EPC + '/EPC_traffic' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
#sftp_module (user, password, EPCMachine, ports, localfile, remotefile, sftp_log, "get")
test_result=test_result & run_result
test_result_string=test_result_string + run_result_string
localfile = logdir_local_testcase + '/EPC_task_out' + '_' + str(run) + '_.log'
remotefile = logdir_EPC + '/EPC_task_out' + '_' + str(run) + '_.log'
paramList.append ( {"operation":'get', "localfile":localfile, "remotefile":remotefile} )
sftp_module (user, password, EPCMachine, ports, paramList, sftp_log)
#We need to close the new ssh session that was created
if index_eNBMachine == index_EPCMachine:
oai_eNB.disconnect()
oai_UE.disconnect()
oai_EPC.disconnect()
#We need to close the new ssh session that was created
#if index_eNBMachine == index_EPCMachine:
# oai_EPC.disconnect()
#Now we finalize the xml file of the test case
end_time=time.time()
duration= end_time - start_time
xmlFile = logdir_local + '/cmake_targets/autotests/log/'+ testcasename + 'test.' + testcasename + '.xml'
if test_result ==0:
result='FAIL'
else:
result = 'PASS'
xml="<testcase classname=\'"+ testcaseclass + "\' name=\'" + testcasename + "."+tags + "\' Run_result=\'" + test_result_string + "\' time=\'" + duration + "\'s RESULT=\'" +result + "\'></testcase>"
write_file(xmlFile, xml, mode="w")
#This function searches if test case is present in list of test cases that need to be executed by user
def search_test_case_group(testcasename, testcasegroup):
......@@ -625,8 +825,8 @@ if openairdir_local is None:
sys.exit()
locallogdir = openairdir_local + '/cmake_targets/autotests/log/'
#Remove the contents of local log directory
os.system(' rm -fr ' + locallogdir + '; mkdir -p ' + locallogdir )
#os.system(' rm -fr ' + locallogdir + '; mkdir -p ' + locallogdir )
flag_remove_logdir=False
i=1
while i < len (sys.argv):
arg=sys.argv[i]
......@@ -637,6 +837,8 @@ while i < len (sys.argv):
elif arg == '-p' :
prompt2 = sys.argv[i+1]
i = i +1
elif arg == '-r':
flag_remove_logdir=True
elif arg == '-w' :
pw = sys.argv[i+1]
i = i +1
......@@ -656,6 +858,7 @@ while i < len (sys.argv):
print "-d: low debug level"
print "-dd: high debug level"
print "-p: set the prompt"
print "-r: Remove the log directory in autotests/"
print "-w: set the password for ssh to localhost"
print "-l: use local shell instead of ssh connection"
print "-t: set the time out in second for commands"
......@@ -683,6 +886,12 @@ except KeyError:
print "Please set the environment variable OPENAIR_TARGETS in the .bashrc"
sys.exit(1)
if flag_remove_logdir == True:
print "Removing directory: " + locallogdir
os.system(' rm -fr ' + locallogdir + '; mkdir -p ' + locallogdir )
paramiko_logfile = os.path.expandvars('$OPENAIR_DIR/cmake_targets/autotests/log/paramiko.log')
res=os.system(' echo > ' + paramiko_logfile)
paramiko.util.log_to_file(paramiko_logfile)
......@@ -714,7 +923,8 @@ GitOAI5GRepoBranch = xmlRoot.findtext('GitOAI5GRepoBranch',default='')
GitOpenaircnRepoBranch = xmlRoot.findtext('GitOpenair-cnRepoBranch',default='')
CleanUpOldProgs = xmlRoot.findtext('CleanUpOldProgs',default='')
CleanUpAluLteBox = xmlRoot.findtext('CleanUpAluLteBox',default='')
Timeout_execution = int (xmlRoot.findtext('Timeout_execution'))
MachineListGeneric = xmlRoot.findtext('MachineListGeneric',default='')
print "MachineList = " + MachineList
print "GitOpenair-cnRepo = " + GitOpenaircnRepo
print "GitOAI5GRepo = " + GitOAI5GRepo
......@@ -725,9 +935,10 @@ cmd = "git show-ref --heads -s "+ GitOAI5GRepoBranch
GitOAI5GHeadVersion = subprocess.check_output ([cmd], shell=True)
print "GitOAI5GHeadVersion = " + GitOAI5GHeadVersion
print "CleanUpOldProgs = " + CleanUpOldProgs
print "Timeout_execution = " + str(Timeout_execution)
MachineList = MachineList.split()
MachineListGeneric = MachineListGeneric.split()
index=0
for machine in MachineList:
......@@ -856,7 +1067,7 @@ for index in oai_list:
#cmd = cmd + 'echo \' ' + cmd + '\' > ' + setup_script + ' 2>&1 \n '
#result = oai_list[index].send_recv(cmd, False, 300 )
write_file(setup_script, cmd, mode="w")
tempThread = oaiThread(index, 'thread_'+str(index), oai_list[index] , cmd, False, 300)
tempThread = oaiThread(index, 'thread_setup_'+str(index)+'_' + MachineList[index] , MachineList[index] , user, pw, cmd, False, 300)
threads_init_setup.append(tempThread )
tempThread.start()
......@@ -891,12 +1102,14 @@ for index in oai_list:
#print '\nCleaning Older running programs : ' + CleanUpOldProgs
#cleanOldPrograms(oai_list[index], CleanUpOldProgs)
except :
except Exception, e:
print 'There is error in one of the commands to setup the machine '+ MachineList[index]
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + traceback.format_exc()
print error
sys.exit(1)
#Now we wait for all the threads to complete
index = 0
for t in threads_init_setup:
......@@ -921,39 +1134,61 @@ for t in threads_init_setup:
index = index+1
#Now we process all the test cases
#Now we check if there was error in setup files
status, out = commands.getstatusoutput('grep ' + ' -il \'error\' ' + locallogdir + '/setup*')
if (out != '') :
print "There is error in setup of machines"
print "status = " + str(status) + "\n out = " + out
print sys.exit(1)
threadListGlobal=[]
testcaseList=xmlRoot.findall('testCase')
#print testcaseList
for testcase in testcaseList:
try:
testcasename = testcase.get('id')
testcaseclass = testcase.findtext('class',default='')
desc = testcase.findtext('desc',default='')
#print "Machine list top level = " + ','.join(MachineList)
if search_test_case_group(testcasename, testcasegroup) == True:
if testcaseclass == 'lte-softmodem' :
eNBMachine = testcase.findtext('eNB',default='')
UEMachine = testcase.findtext('UE',default='')
EPCMachine = testcase.findtext('EPC',default='')
index_eNBMachine = MachineList.index(eNBMachine)
index_UEMachine = MachineList.index(UEMachine)
index_EPCMachine = MachineList.index(EPCMachine)
#index_eNBMachine = MachineList.index(eNBMachine)
#index_UEMachine = MachineList.index(UEMachine)
#index_EPCMachine = MachineList.index(EPCMachine)
if (eNBMachine not in MachineList)|(UEMachine not in MachineList)|(UEMachine not in MachineList):
print "One of the machines is not in the machine list"
print "eNBMachine : " + eNBMachine + "UEMachine : " + UEMachine + "EPCMachine : " + EPCMachine + "MachineList : " + ','.join(MachineList)
print "testcasename = " + testcasename + " class = " + testcaseclass
handle_testcaseclass_softmodem (testcase, CleanUpOldProgs, oai_list, logdirOAI5GRepo, logdirOpenaircnRepo, MachineList, pw, CleanUpAluLteBox )
elif testcaseclass == 'compilation' :
continue
handle_testcaseclass_compilation (testcase)
elif testcaseclass == 'execution' :
continue
handle_testcaseclass_oaisim (testcase)
threadListGlobal = wait_testcaseclass_generic_threads(threadListGlobal, Timeout_execution)
handle_testcaseclass_softmodem (testcase, CleanUpOldProgs, logdirOAI5GRepo, logdirOpenaircnRepo, MachineList, pw, CleanUpAluLteBox )
elif (testcaseclass == 'compilation'):
threadListGlobal = handle_testcaseclass_generic (testcasename, threadListGlobal, CleanUpOldProgs, logdirOAI5GRepo, MachineListGeneric, pw, CleanUpAluLteBox,Timeout_execution)
elif (testcaseclass == 'execution'):
threadListGlobal = handle_testcaseclass_generic (testcasename, threadListGlobal, CleanUpOldProgs, logdirOAI5GRepo, MachineListGeneric, pw, CleanUpAluLteBox,Timeout_execution)
else :
print "Unknown test case class: " + testcaseclass
sys.exit()
except Exception, e:
error=''
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
error = error + '\n testcasename = ' + testcasename + '\n testcaseclass = ' + testcaseclass + '\n desc = ' + 'desc' + '\n'
error = error + traceback.format_exc()
print error
sys.exit(1)
print "Exiting the test cases execution now..."
sys.exit()
for t in threadListGlobal:
t.join
sys.exit()
#+ "class = "+ classx
......
<testCaseList>
<MachineList>amerique stevens calisson nano</MachineList>
<MachineList>stevens calisson mozart nano amerique</MachineList>
<NFSResultsShare>/mnt/sradio/TEST_RESULTS</NFSResultsShare>
<GitOAI5GRepo>https://gitlab.eurecom.fr/oai/openairinterface5g.git</GitOAI5GRepo>
<GitOpenair-cnRepo>https://gitlab.eurecom.fr/oai/openair-cn.git</GitOpenair-cnRepo>
<GitOAI5GRepoBranch>feature-34-test_framework</GitOAI5GRepoBranch>
<GitOpenair-cnRepoBranch>feature-17-test_framework</GitOpenair-cnRepoBranch>
<CleanUpOldProgs>oaisim* oaisim_nos1* lte-softmodem* lte-softmodem-nos1* mme_gw* run_epc* run_hss* iperf* hss hss_sim configure_cots_bandrich_ue* wvdial* </CleanUpOldProgs>
<CleanUpOldProgs>oaisim* oaisim_nos1* lte-softmodem* lte-softmodem-nos1* mme_gw* run_epc* run_hss* iperf* hss hss_sim configure_cots_bandrich_ue* wvdial* run_exec_autotests*</CleanUpOldProgs>
<CleanUpAluLteBox>/opt/ltebox/tools/stop_ltebox</CleanUpAluLteBox>
<Timeout_execution>1800</Timeout_execution>
<MachineListGeneric>calisson stevens mozart nano amerique</MachineListGeneric>
<testCase id="010101" >
<class>compilation</class>
<desc>Build oaisim.Rel8</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim -r Rel8</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/oaisim_build_oai/build/oaisim
$OPENAIR_DIR/cmake_targets/at_commands/build/at_nas_ue
$OPENAIR_DIR/cmake_targets/nas_sim_tools/build/usim
$OPENAIR_DIR/cmake_targets/nas_sim_tools/build/nvram</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>oaisim.Rel8</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010102" >
<class>compilation</class>
<desc>Build oaisim.Rel8 + network device driver(nasmesh_fix)</desc>
<desc>Build oaisim.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim -r Rel10</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/oaisim_build_oai/build/oaisim
$OPENAIR_DIR/cmake_targets/at_commands/build/at_nas_ue
$OPENAIR_DIR/cmake_targets/nas_sim_tools/build/usim
$OPENAIR_DIR/cmake_targets/nas_sim_tools/build/nvram</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>oaisim.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010103" >
<class>compilation</class>
<desc>Build lte-softmodem EXMIMO.Rel8 + EXMIMO.Rel10 + USRP.Rel10</desc>
<pre_compile_prog>cp -vf ../CMakeLists.txt.Rel8 ../CMakeLists.txt
cp -vf ../CMakeLists.txt.Rel10 ../CMakeLists.txt
cp -vf ../CMakeLists.txt.USRP ../CMakeLists.txt </pre_compile_prog>
<compile_prog>lte-softmodem</compile_prog>
<compile_prog_args></compile_prog_args>
<desc>Build oaisim_noS1.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim -r Rel10 --noS1</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1
$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/rb_tool
$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/CMakeFiles/nasmesh/nasmesh.ko
$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/CMakeFiles/oai_nw_drv/oai_nw_drv.ko</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>oaisim_noS1.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010104" >
<testCase id="010110" >
<class>compilation</class>
<desc>Build phy unitary simulators + secuirity unitary tests</desc>
<desc>Build lte_softmodem_noS1.USRP.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>dlsim ulsim pucchsim prachsim pdcchsim pbchsim mbmssim test_secu_knas_encrypt_eia1 test_secu_kenb test_aes128_ctr_encrypt test_aes128_ctr_decrypt test_secu_knas_encrypt_eea2 test_secu_knas test_secu_knas_encrypt_eea1 test_kdf test_aes128_cmac_encrypt test_secu_knas_encrypt_eia2</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--eNB -w USRP -r Rel10 --noS1</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/lte-softmodem-nos1
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/rb_tool
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/CMakeFiles/nasmesh/nasmesh.ko</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>lte-softmodem_noS1.USRP.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010106" >
<testCase id="010111" >
<class>compilation</class>
<desc>Build oaisim.Rel8 + ITTI</desc>
<desc>Build lte_softmodem_noS1.EXMIMO.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--eNB -w EXMIMO -r Rel10 --noS1</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/lte-softmodem-nos1
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/rb_tool
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/CMakeFiles/nasmesh/nasmesh.ko
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/CMakeFiles/openair_rf/openair_rf.ko
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/updatefw
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/oarf_config_exmimo.oct</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>lte-softmodem_noS1.EXMIMO.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010107" >
<testCase id="010112" >
<class>compilation</class>
<desc>Build oaisim_nos1.Rel10</desc>
<desc>Build lte_softmodem_noS1.BLADERF.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--eNB -w BLADERF -r Rel10 --noS1</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/lte-softmodem-nos1
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/rb_tool
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/CMakeFiles/nasmesh/nasmesh.ko</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>lte-softmodem_noS1.EXMIMO.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010108" >
<testCase id="010113" >
<class>compilation</class>
<desc>Build oaisim.Rel10 + ITTI</desc>
<desc>Build lte_softmodem_noS1.ETHERNET.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--eNB -w ETHERNET -r Rel10 --noS1</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/lte-softmodem-nos1
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/rb_tool
$OPENAIR_DIR/cmake_targets/lte_noS1_build_oai/build/CMakeFiles/nasmesh/nasmesh.ko</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>lte-softmodem_noS1.ETHERNET.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010120" >
<class>compilation</class>
<desc>Build Nasmesh</desc>
<desc>Build lte_softmodem.USRP.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>nasmesh</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog_out>CMakeFiles/nasmesh/nasmesh.ko</compile_prog_out>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--eNB -w USRP -r Rel10 </compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/lte_build_oai/build/lte-softmodem</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>lte-softmodem.USRP.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010121" >
<class>compilation</class>
<desc>Build lte_softmodem.EXMIMO.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--eNB -w EXMIMO -r Rel10 </compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/lte_build_oai/build/lte-softmodem
$OPENAIR_DIR/cmake_targets/lte_build_oai/build/CMakeFiles/openair_rf/openair_rf.ko
$OPENAIR_DIR/cmake_targets/lte_build_oai/build/updatefw
$OPENAIR_DIR/cmake_targets/lte_build_oai/build/oarf_config_exmimo.oct</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>lte-softmodemEXMIMO.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010122" >
<class>compilation</class>
<desc>Build lte_softmodem.BLADERF.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--eNB -w BLADERF -r Rel10 </compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/lte_build_oai/build/lte-softmodem</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>lte-softmodem.EXMIMO.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010123" >
<class>compilation</class>
<desc>Build lte_softmodem.ETHERNET.Rel10</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--eNB -w ETHERNET -r Rel10 </compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/lte_build_oai/build/lte-softmodem</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>lte-softmodem.ETHERNET.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010130" >
<class>compilation</class>
<desc>Build phy unitary simulators + secuirity unitary tests</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--phy_simulators --core_simulators</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/lte-simulators/build/dlsim
$OPENAIR_DIR/cmake_targets/lte-simulators/build/ulsim
$OPENAIR_DIR/cmake_targets/lte-simulators/build/pucchsim
$OPENAIR_DIR/cmake_targets/lte-simulators/build/prachsim
$OPENAIR_DIR/cmake_targets/lte-simulators/build/pdcchsim
$OPENAIR_DIR/cmake_targets/lte-simulators/build/pbchsim
$OPENAIR_DIR/cmake_targets/lte-simulators/build/mbmssim
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas_encrypt_eia1
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_kenb
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_aes128_ctr_encrypt
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_aes128_ctr_decrypt
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas_encrypt_eea2
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas_encrypt_eea1
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_kdf
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_aes128_cmac_encrypt
$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas_encrypt_eia2</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>unitary-sim.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010140" >
<class>compilation</class>
<desc>Build RRH Gateway</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--RRH -w USRP</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/rrh_gw/build/rrh_gw</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>RRH.USRP.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010141" >
<class>compilation</class>
<desc>Build RRH Gateway</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--RRH -w EXMIMO</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/rrh_gw/build/rrh_gw
$OPENAIR_DIR/cmake_targets/rrh_gw/build/CMakeFiles/openair_rf/openair_rf.ko
$OPENAIR_DIR/cmake_targets/rrh_gw/build/updatefw
$OPENAIR_DIR/cmake_targets/rrh_gw/build/oarf_config_exmimo.oct</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>RRH.EXMIMO.Rel10</tags>
<nruns>1</nruns>
</testCase>
<testCase id="010142" >
<class>compilation</class>
<desc>Build RRH Gateway</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>rrh_gw</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--RRH -w BLADERF</compile_prog_args>
<compile_prog_out>$OPENAIR_DIR/cmake_targets/rrh_gw/build/rrh_gw</compile_prog_out>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec></main_exec>
<main_exec_args></main_exec_args>
<search_expr_true></search_expr_true>
<search_expr_false></search_expr_false>
<tags>RRH.BLADERF.Rel10</tags>
<nruns>1</nruns>
</testCase>
......@@ -153,11 +315,11 @@
<class>execution</class>
<desc>Run OAISIM Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 1
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 1
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 1
......@@ -170,7 +332,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 6
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 6
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 6</main_exec_args>
<tags>tdd.5MHz.TM1 tdd.10MHz.TM1 tdd.20MHz.TM1 tdd.5MHz.TM2 tdd.10MHz.TM2 tdd.20MHz.TM2 tdd.5MHz.TM5 tdd.10MHz.TM5 tdd.20MHz.TM5 tdd.5MHz.TM6 tdd.10MHz.TM6 tdd.20MHz.TM6</tags>
<tags>oaisim_noS1.tdd.5MHz.TM1 oaisim_noS1.tdd.10MHz.TM1 oaisim_noS1.tdd.20MHz.TM1 oaisim_noS1.tdd.5MHz.TM2 oaisim_noS1.tdd.10MHz.TM2 oaisim_noS1.tdd.20MHz.TM2 oaisim_noS1.tdd.5MHz.TM5 oaisim_noS1.tdd.10MHz.TM5 oaisim_noS1.tdd.20MHz.TM5 oaisim_noS1.tdd.5MHz.TM6 oaisim_noS1.tdd.10MHz.TM6 oaisim_noS1.tdd.20MHz.TM6</tags>
<search_expr_true>"Received RRCConnectionReconfigurationComplete from UE 0"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -180,11 +342,11 @@
<class>execution</class>
<desc>Run OAISIM Rel10 TDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors, segmentation fault or exit</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 1 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 1 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 1 -a
......@@ -197,7 +359,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 6 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 6 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 6 -a</main_exec_args>
<tags>tdd.5MHz.TM1 tdd.10MHz.TM1 tdd.20MHz.TM1 tdd.5MHz.TM2 tdd.10MHz.TM2 tdd.20MHz.TM2 tdd.5MHz.TM5 tdd.10MHz.TM5 tdd.20MHz.TM5 tdd.5MHz.TM6 tdd.10MHz.TM6 tdd.20MHz.TM6</tags>
<tags>oaisim_noS1.tdd.5MHz.TM1 oaisim_noS1.tdd.10MHz.TM1 oaisim_noS1.tdd.20MHz.TM1 oaisim_noS1.tdd.5MHz.TM2 oaisim_noS1.tdd.10MHz.TM2 oaisim_noS1.tdd.20MHz.TM2 oaisim_noS1.tdd.5MHz.TM5 oaisim_noS1.tdd.10MHz.TM5 oaisim_noS1.tdd.20MHz.TM5 oaisim_noS1.tdd.5MHz.TM6 oaisim_noS1.tdd.10MHz.TM6 oaisim_noS1.tdd.20MHz.TM6</tags>
<search_expr_true>"Received RRCConnectionReconfigurationComplete from UE 0"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -207,11 +369,11 @@
<class>execution</class>
<desc>Run OAISIM Rel10 TDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 1
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 1
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 1
......@@ -224,7 +386,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 6
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 6
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 6 </main_exec_args>
<tags>tdd.5MHz.TM1 tdd.10MHz.TM1 tdd.20MHz.TM1 tdd.5MHz.TM2 tdd.10MHz.TM2 tdd.20MHz.TM2 tdd.5MHz.TM5 tdd.10MHz.TM5 tdd.20MHz.TM5 tdd.5MHz.TM6 tdd.10MHz.TM6 tdd.20MHz.TM6</tags>
<tags>oaisim_noS1.tdd.5MHz.TM1 oaisim_noS1.tdd.10MHz.TM1 oaisim_noS1.tdd.20MHz.TM1 oaisim_noS1.tdd.5MHz.TM2 oaisim_noS1.tdd.10MHz.TM2 oaisim_noS1.tdd.20MHz.TM2 oaisim_noS1.tdd.5MHz.TM5 oaisim_noS1.tdd.10MHz.TM5 oaisim_noS1.tdd.20MHz.TM5 oaisim_noS1.tdd.5MHz.TM6 oaisim_noS1.tdd.10MHz.TM6 oaisim_noS1.tdd.20MHz.TM6</tags>
<search_expr_true>"Received RRCConnectionReconfigurationComplete from UE 0" "Received RRCConnectionReconfigurationComplete from UE 1" "Received RRCConnectionReconfigurationComplete from UE 2"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -234,11 +396,11 @@
<class>execution</class>
<desc>Run OAISIM Rel10 TDD, 1 eNB + 3 UEs (5 MHz) in PHY_ABSTRACTION mode and search for errors, segmentation fault or exit</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 1 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 1 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 1 -a
......@@ -251,7 +413,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 6 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 6 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 6 -a</main_exec_args>
<tags>tdd.5MHz.TM1 tdd.10MHz.TM1 tdd.20MHz.TM1 tdd.5MHz.TM2 tdd.10MHz.TM2 tdd.20MHz.TM2 tdd.5MHz.TM5 tdd.10MHz.TM5 tdd.20MHz.TM5 tdd.5MHz.TM6 tdd.10MHz.TM6 tdd.20MHz.TM6</tags>
<tags>oaisim_noS1.tdd.5MHz.TM1 oaisim_noS1.tdd.10MHz.TM1 oaisim_noS1.tdd.20MHz.TM1 oaisim_noS1.tdd.5MHz.TM2 oaisim_noS1.tdd.10MHz.TM2 tdd.20MHz.TM2 oaisim_noS1.tdd.5MHz.TM5 oaisim_noS1.tdd.10MHz.TM5 oaisim_noS1.tdd.20MHz.TM5 oaisim_noS1.tdd.5MHz.TM6 oaisim_noS1.tdd.10MHz.TM6 oaisim_noS1.tdd.20MHz.TM6</tags>
<search_expr_true>"Received RRCConnectionReconfigurationComplete from UE 0" "Received RRCConnectionReconfigurationComplete from UE 1" "Received RRCConnectionReconfigurationComplete from UE 2"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -261,11 +423,11 @@
<class>execution</class>
<desc>Run OAI Rel10 TDD, 1 eNB + 1 UE (5 MHz) without abstraction mode, send ping from from eNB to UE, and check that there is no packet losses</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 1 -c26
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 1 -c26
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 1 -c26
......@@ -278,7 +440,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 6 -c26
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 6 -c26
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 6 -c26 </main_exec_args>
<tags>tdd.5MHz.TM1 tdd.10MHz.TM1 tdd.20MHz.TM1 tdd.5MHz.TM2 tdd.10MHz.TM2 tdd.20MHz.TM2 tdd.5MHz.TM5 tdd.10MHz.TM5 tdd.20MHz.TM5 tdd.5MHz.TM6 tdd.10MHz.TM6 tdd.20MHz.TM6</tags>
<tags>oaisim_noS1.tdd.5MHz.TM1 oaisim_noS1.tdd.10MHz.TM1 oaisim_noS1.tdd.20MHz.TM1 oaisim_noS1.tdd.5MHz.TM2 oaisim_noS1.tdd.10MHz.TM2 oaisim_noS1.tdd.20MHz.TM2 oaisim_noS1.tdd.5MHz.TM5 oaisim_noS1.tdd.10MHz.TM5 oaisim_noS1.tdd.20MHz.TM5 oaisim_noS1.tdd.5MHz.TM6 oaisim_noS1.tdd.10MHz.TM6 oaisim_noS1.tdd.20MHz.TM6</tags>
<search_expr_true>"DL and UL loss rate below 10"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -288,11 +450,11 @@
<class>execution</class>
<desc>Run OAI Rel10 TDD, 1 eNB + 1 UE (5 MHz) in PHY_ABSTRACTION mode, send ping from from eNB to UE, and check that there is no packet losses</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 1 -c26 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 1 -c26 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 1 -c26 -a
......@@ -305,7 +467,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 6 -c26 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 6 -c26 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 6 -c26 -a </main_exec_args>
<tags>tdd.5MHz.TM1 tdd.10MHz.TM1 tdd.20MHz.TM1 tdd.5MHz.TM2 tdd.10MHz.TM2 tdd.20MHz.TM2 tdd.5MHz.TM5 tdd.10MHz.TM5 tdd.20MHz.TM5 tdd.5MHz.TM6 tdd.10MHz.TM6 tdd.20MHz.TM6</tags>
<tags>oaisim_noS1.tdd.5MHz.TM1 oaisim_noS1.tdd.10MHz.TM1 oaisim_noS1.tdd.20MHz.TM1 oaisim_noS1.tdd.5MHz.TM2 oaisim_noS1.tdd.10MHz.TM2 oaisim_noS1.tdd.20MHz.TM2 oaisim_noS1.tdd.5MHz.TM5 oaisim_noS1.tdd.10MHz.TM5 tdd.20MHz.TM5 oaisim_noS1.tdd.5MHz.TM6 oaisim_noS1.tdd.10MHz.TM6 oaisim_noS1.tdd.20MHz.TM6</tags>
<search_expr_true>"DL and UL loss rate below 10"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -315,11 +477,11 @@
<class>execution</class>
<desc>Run OAISIM Rel10 FDD, 1 eNB + 1 UE 1 eNB (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 1 -F
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 1 -F
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 1 -F
......@@ -332,7 +494,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 6 -F
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 6 -F
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 6 -F</main_exec_args>
<tags>FDD.5MHz.TM1 FDD.10MHz.TM1 FDD.20MHz.TM1 FDD.5MHz.TM2 FDD.10MHz.TM2 FDD.20MHz.TM2 FDD.5MHz.TM5 FDD.10MHz.TM5 FDD.20MHz.TM5 FDD.5MHz.TM6 FDD.10MHz.TM6 FDD.20MHz.TM6</tags>
<tags>oaisim_noS1.FDD.5MHz.TM1 oaisim_noS1.FDD.10MHz.TM1 oaisim_noS1.FDD.20MHz.TM1 oaisim_noS1.FDD.5MHz.TM2 oaisim_noS1.FDD.10MHz.TM2 oaisim_noS1.FDD.20MHz.TM2 oaisim_noS1.FDD.5MHz.TM5 oaisim_noS1.FDD.10MHz.TM5 oaisim_noS1.FDD.20MHz.TM5 oaisim_noS1.FDD.5MHz.TM6 oaisim_noS1.FDD.10MHz.TM6 oaisim_noS1.FDD.20MHz.TM6</tags>
<search_expr_true>"Received RRCConnectionReconfigurationComplete from UE 0"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -342,11 +504,11 @@
<class>execution</class>
<desc>Run OAISIM Rel10 FDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 1 -F -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 1 -F -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 1 -F -a
......@@ -359,7 +521,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 6 -F -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 6 -F -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 6 -F -a</main_exec_args>
<tags>FDD.5MHz.TM1 FDD.10MHz.TM1 FDD.20MHz.TM1 FDD.5MHz.TM2 FDD.10MHz.TM2 FDD.20MHz.TM2 FDD.5MHz.TM5 FDD.10MHz.TM5 FDD.20MHz.TM5 FDD.5MHz.TM6 FDD.10MHz.TM6 FDD.20MHz.TM6</tags>
<tags>oaisim_noS1.FDD.5MHz.TM1 oaisim_noS1.FDD.10MHz.TM1 oaisim_noS1.FDD.20MHz.TM1 oaisim_noS1.FDD.5MHz.TM2 oaisim_noS1.FDD.10MHz.TM2 oaisim_noS1.FDD.20MHz.TM2 oaisim_noS1.FDD.5MHz.TM5 oaisim_noS1.FDD.10MHz.TM5 oaisim_noS1.FDD.20MHz.TM5 oaisim_noS1.FDD.5MHz.TM6 oaisim_noS1.FDD.10MHz.TM6 oaisim_noS1.FDD.20MHz.TM6</tags>
<search_expr_true>"Received RRCConnectionReconfigurationComplete from UE 0"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -369,11 +531,11 @@
<class>execution</class>
<desc> Run OAISIM Rel10 FDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) and search for errors, segmentation fault or exit</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 1 -F
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 1 -F
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 1 -F
......@@ -386,7 +548,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 6 -F
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 6 -F
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 6 -F </main_exec_args>
<tags>FDD.5MHz.TM1 FDD.10MHz.TM1 FDD.20MHz.TM1 FDD.5MHz.TM2 FDD.10MHz.TM2 FDD.20MHz.TM2 FDD.5MHz.TM5 FDD.10MHz.TM5 FDD.20MHz.TM5 FDD.5MHz.TM6 FDD.10MHz.TM6 FDD.20MHz.TM6</tags>
<tags>oaisim_noS1.FDD.5MHz.TM1 oaisim_noS1.FDD.10MHz.TM1 oaisim_noS1.FDD.20MHz.TM1 oaisim_noS1.FDD.5MHz.TM2 oaisim_noS1.FDD.10MHz.TM2 oaisim_noS1.FDD.20MHz.TM2 oaisim_noS1.FDD.5MHz.TM5 oaisim_noS1.FDD.10MHz.TM5 oaisim_noS1.FDD.20MHz.TM5 oaisim_noS1.FDD.5MHz.TM6 oaisim_noS1.FDD.10MHz.TM6 oaisim_noS1.FDD.20MHz.TM6</tags>
<search_expr_true>"Received RRCConnectionReconfigurationComplete from UE 0" "Received RRCConnectionReconfigurationComplete from UE 1" "Received RRCConnectionReconfigurationComplete from UE 2"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -396,11 +558,11 @@
<class>execution</class>
<desc>Run OAISIM Rel10 FDD, 1 eNB + 3 UEs (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode and search for errors</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 1 -F -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 1 -F -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 1 -F -a
......@@ -413,7 +575,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 25 -x 6 -F -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 50 -x 6 -F -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u3 -n100 -R 100 -x 6 -F -a</main_exec_args>
<tags>FDD.5MHz.TM1 FDD.10MHz.TM1 FDD.20MHz.TM1 FDD.5MHz.TM2 FDD.10MHz.TM2 FDD.20MHz.TM2 FDD.5MHz.TM5 FDD.10MHz.TM5 FDD.20MHz.TM5 FDD.5MHz.TM6 FDD.10MHz.TM6 FDD.20MHz.TM6</tags>
<tags>oaisim_noS1.FDD.5MHz.TM1 oaisim_noS1.FDD.10MHz.TM1 oaisim_noS1.FDD.20MHz.TM1 oaisim_noS1.FDD.5MHz.TM2 oaisim_noS1.FDD.10MHz.TM2 oaisim_noS1.FDD.20MHz.TM2 oaisim_noS1.FDD.5MHz.TM5 oaisim_noS1.FDD.10MHz.TM5 oaisim_noS1.FDD.20MHz.TM5 oaisim_noS1.FDD.5MHz.TM6 oaisim_noS1.FDD.10MHz.TM6 oaisim_noS1.FDD.20MHz.TM6</tags>
<search_expr_true>"Received RRCConnectionReconfigurationComplete from UE 0" "Received RRCConnectionReconfigurationComplete from UE 1" "Received RRCConnectionReconfigurationComplete from UE 2"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -423,11 +585,11 @@
<class>execution</class>
<desc>Run OAI Rel10 FDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) without PHY_ABSTRACTION mode, ping from from eNB to UE, and for check for no packet losses</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 1 -F -c26
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 1 -F -c26
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 1 -F -c26
......@@ -440,7 +602,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 6 -F -c26
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 6 -F -c26
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 6 -F -c26</main_exec_args>
<tags>FDD.5MHz.TM1 FDD.10MHz.TM1 FDD.20MHz.TM1 FDD.5MHz.TM2 FDD.10MHz.TM2 FDD.20MHz.TM2 FDD.5MHz.TM5 FDD.10MHz.TM5 FDD.20MHz.TM5 FDD.5MHz.TM6 FDD.10MHz.TM6 FDD.20MHz.TM6</tags>
<tags>oaisim_noS1.FDD.5MHz.TM1 oaisim_noS1.FDD.10MHz.TM1 oaisim_noS1.FDD.20MHz.TM1 oaisim_noS1.FDD.5MHz.TM2 oaisim_noS1.FDD.10MHz.TM2 oaisim_noS1.FDD.20MHz.TM2 oaisim_noS1.FDD.5MHz.TM5 oaisim_noS1.FDD.10MHz.TM5 oaisim_noS1.FDD.20MHz.TM5 oaisim_noS1.FDD.5MHz.TM6 oaisim_noS1.FDD.10MHz.TM6 oaisim_noS1.FDD.20MHz.TM6</tags>
<search_expr_true>"DL and UL loss rate below 10"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -450,11 +612,11 @@
<class>execution</class>
<desc>Run OAI Rel10 FDD, 1 eNB + 1 UE (5 MHz/10MHz/20MHz), (TM 1,2,5,6) in PHY_ABSTRACTION mode, send ping from from eNB to UE, and check for no packet losses</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 1 -F -c26 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 1 -F -c26 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 1 -F -c26 -a
......@@ -467,7 +629,7 @@
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 25 -x 6 -F -c26 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 50 -x 6 -F -c26 -a
-O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -b1 -u1 -n100 -R 100 -x 6 -F -c26 -a </main_exec_args>
<tags>FDD.5MHz.TM1 FDD.10MHz.TM1 FDD.20MHz.TM1 FDD.5MHz.TM2 FDD.10MHz.TM2 FDD.20MHz.TM2 FDD.5MHz.TM5 FDD.10MHz.TM5 FDD.20MHz.TM5 FDD.5MHz.TM6 FDD.10MHz.TM6 FDD.20MHz.TM6</tags>
<tags>oaisim_noS1.FDD.5MHz.TM1 oaisim_noS1.FDD.10MHz.TM1 oaisim_noS1.FDD.20MHz.TM1 oaisim_noS1.FDD.5MHz.TM2 oaisim_noS1.FDD.10MHz.TM2 oaisim_noS1.FDD.20MHz.TM2 oaisim_noS1.FDD.5MHz.TM5 oaisim_noS1.FDD.10MHz.TM5 oaisim_noS1.FDD.20MHz.TM5 oaisim_noS1.FDD.5MHz.TM6 oaisim_noS1.FDD.10MHz.TM6 oaisim_noS1.FDD.20MHz.TM6</tags>
<search_expr_true>"DL and UL loss rate below 10"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns>
......@@ -477,14 +639,15 @@
<class>execution</class>
<desc>Check if eMBMS procedure is not finished completely, make sure that the SIB13/MCCH have been correclty received by UEs</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -l7 -x 1 -Q3 -n 100 -b1 -u1</main_exec_args>
<search_expr_true>"Found MBSFNAreaConfiguration from eNB 0"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>oaisim_noS1.eMBMS</tags>
<nruns>3</nruns>
</testCase>
......@@ -492,14 +655,15 @@
<class>execution</class>
<desc>Check if eMBMS multicast/broadcast data is received, make sure that the SIB13/MCCH/MTCH have been correclty received by UEs</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -l7 -x 1 -T mscbr -Q3 -n 100 -b1 -u1</main_exec_args>
<search_expr_true>"Received a multicast packet"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>oaisim_noS1.eMBMS</tags>
<nruns>3</nruns>
</testCase>
......@@ -507,14 +671,15 @@
<class>execution</class>
<desc>Check for eMBMS multicast/broadcast data received in fdd mode, make sure that the SIB13/MCCH/MTCH have been correclty received by UEs</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -l7 -F -T mscbr -x 1 -Q3 -n 100 -b1 -u1</main_exec_args>
<search_expr_true>"Received a multicast packet"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>oaisim_noS1.eMBMS</tags>
<nruns>3</nruns>
</testCase>
......@@ -522,14 +687,15 @@
<class>execution</class>
<desc>Check for eMBMS multicast/broadcast DF relaying working properly in fdd mode, make sure that the SIB13/MCCH/MTCH have been correclty received by UEs</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>oaisim_nos1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args>--oaisim --noS1</compile_prog_args>
<pre_exec>$OPENAIR_DIR/cmake_targets/tools/init_nas_nos1</pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>oaisim_nos1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/oaisim_noS1_build_oai/build/oaisim_nos1</main_exec>
<main_exec_args> -O $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.generic.oaisim.local_no_mme.conf -A AWGN -l7 -c43 -F -T mbvbr -Q4 -j1 -n120</main_exec_args>
<search_expr_true>"MTCH for sync area 1"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>oaisim_noS1.eMBMS</tags>
<nruns>3</nruns>
</testCase>
......@@ -537,14 +703,15 @@
<class>execution</class>
<desc>test_aes128_cmac_encrypt</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_aes128_cmac_encrypt</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_aes128_cmac_encrypt</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_aes128_cmac_encrypt</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_aes128_cmac_encrypt</tags>
<nruns>3</nruns>
</testCase>
......@@ -552,14 +719,15 @@
<class>execution</class>
<desc>test_aes128_ctr_decrypt</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_aes128_ctr_decrypt</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_aes128_ctr_decrypt</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_aes128_ctr_decrypt</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_aes128_ctr_decrypt</tags>
<nruns>3</nruns>
</testCase>
......@@ -567,14 +735,15 @@
<class>execution</class>
<desc>test_aes128_ctr_encrypt</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_aes128_ctr_encrypt</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_aes128_ctr_encrypt</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_aes128_ctr_encrypt</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_aes128_ctr_encrypt</tags>
<nruns>3</nruns>
</testCase>
......@@ -582,14 +751,15 @@
<class>execution</class>
<desc>test_secu_kenb</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_secu_kenb</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_secu_kenb</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_kenb</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_secu_kenb</tags>
<nruns>3</nruns>
</testCase>
......@@ -597,14 +767,15 @@
<class>execution</class>
<desc>test_secu_knas</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_secu_knas</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_secu_knas</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_secu_knas</tags>
<nruns>3</nruns>
</testCase>
......@@ -612,14 +783,15 @@
<class>execution</class>
<desc>test_secu_knas_encrypt_eea1</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_secu_knas_encrypt_eea1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_secu_knas_encrypt_eea1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas_encrypt_eea1</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_secu_knas_encrypt_eea1</tags>
<nruns>3</nruns>
</testCase>
......@@ -627,14 +799,15 @@
<class>execution</class>
<desc>test_secu_knas_encrypt_eea2</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_secu_knas_encrypt_eea2</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_secu_knas_encrypt_eea2</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas_encrypt_eea2</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_secu_knas_encrypt_eea2</tags>
<nruns>3</nruns>
</testCase>
......@@ -642,14 +815,15 @@
<class>execution</class>
<desc>test_secu_knas_encrypt_eia1</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_secu_knas_encrypt_eia1</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_secu_knas_encrypt_eia1</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas_encrypt_eia1</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_secu_knas_encrypt_eia1</tags>
<nruns>3</nruns>
</testCase>
......@@ -657,14 +831,15 @@
<class>execution</class>
<desc>test_secu_knas_encrypt_eia2</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_secu_knas_encrypt_eia2</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_secu_knas_encrypt_eia2</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_secu_knas_encrypt_eia1</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_secu_knas_encrypt_eia2</tags>
<nruns>3</nruns>
</testCase>
......@@ -672,14 +847,15 @@
<class>execution</class>
<desc>test_kdf</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>test_kdf</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --core_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>test_kdf</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/test_kdf</main_exec>
<main_exec_args> --verbose</main_exec_args>
<search_expr_true>"finished with 0 errors"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<tags>test_kdf</tags>
<nruns>3</nruns>
</testCase>
......@@ -698,11 +874,11 @@
(TM2 Test 1b 20 MHz, R.11-2 FDD (MCS 13), EVA5, 5.9 dB (70%)),
</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>dlsim</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --phy_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>dlsim</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/dlsim</main_exec>
<main_exec_args> -m5 -gF -s-1 -w1.0 -f.2 -n500 -B50 -c2 -z2 -O70 -L
-m4 -gF -s0 -w1.0 -f.2 -n500 -B6 -c4 -z2 -O70
-m15 -gF -s6.7 -w1.0 -f.2 -n500 -B50 -c2 -z2 -O70 -L
......@@ -714,7 +890,7 @@
-m26 -gF -s17.7 -w1.0 -f.2 -n500 -B50 -c2 -z2 -O70 -L
-m14 -gF -s6.8 -w1.0 -f.2 -n500 -B50 -c2 -x2 -y2 -z2 -O70 -L
-m13 -gF -s5.9 -w1.0 -f.2 -n500 -B25 -c3 -x2 -y2 -z2 -O70 -L</main_exec_args>
<tags>test1 test5 test6 test6b test7 test7b test10 test10b test11 TM2_test1 TM2_test1b</tags>
<tags>dlsim.test1 dlsim.test5 dlsim.test6 dlsim.test6b dlsim.test7 dlsim.test7b dlsim.test10 dlsim.test10b dlsim.test11 dlsim.TM2_test1 dlsim.TM2_test1b</tags>
<search_expr_true>"passed"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>1</nruns>
......@@ -729,18 +905,18 @@
(Test 5, 20 MHz, FDD (MCS 5), AWGN, 6dB (70%)),
(Test 6, 20 MHz, FDD (MCS 16), AWGN, 12 dB (70%))</desc>
<pre_compile_prog></pre_compile_prog>
<compile_prog>ulsim</compile_prog>
<compile_prog_args></compile_prog_args>
<compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</compile_prog>
<compile_prog_args> --phy_simulators</compile_prog_args>
<pre_exec></pre_exec>
<pre_exec_args></pre_exec_args>
<main_exec>ulsim</main_exec>
<main_exec>$OPENAIR_DIR/cmake_targets/lte-simulators/build/ulsim</main_exec>
<main_exec_args> -B25 -m5 -y1 -gN -x1 -s6 -w1.0 -e.1 -P -n500 -O70 -L
-B25 -m16 -y1 -gN -x1 -s12 -w1.0 -e.1 -P -n500 -O70 -L
-B50 -m5 -y1 -gN -x1 -s6 -w1.0 -e.1 -P -n500 -O70 -L
-B50 -m16 -y1 -gN -x1 -s12 -w1.0 -e.1 -P -n500 -O70 -L
-B100 -m5 -y1 -gN -x1 -s6 -w1.0 -e.1 -P -n500 -O70 -L
-B100 -m16 -y1 -gN -x1 -s12 -w1.0 -e.1 -P -n500 -O70 -L</main_exec_args>
<tags>test1 test2 test3 test4 test5 test6</tags>
<tags>ulsim.test1 ulsim.test2 ulsim.test3 ulsim.test4 ulsim.test5 ulsim.test6</tags>
<search_expr_true>"passed"</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>1</nruns>
......@@ -752,8 +928,7 @@
<eNB>calisson</eNB>
<UE>stevens</UE>
<EPC>amerique</EPC>
<cleanupScript>oaisim* oaisim_nos1* lte-softmodem* lte-softmodem-nos1* mme_gw* run_epc* run_hss* iperf* ltebox*</cleanupScript>
<TimeOut_cmd>60</TimeOut_cmd>
<TimeOut_cmd>180</TimeOut_cmd>
<eNB_working_dir>/tmp</eNB_working_dir>
<eNB_config_file>targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.local.conf tracking_area_code \"1\"
targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.local.conf mobile_country_code \"208\"
......@@ -761,15 +936,15 @@
targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.remote.conf tracking_area_code \"1\"
targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.remote.conf mobile_country_code \"208\"
targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.remote.conf mobile_network_code \"92\"
targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.remote.conf N_RB_DL 50
targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.remote.conf N_RB_DL 25
targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.remote.conf mme_ip_address "ipv4=\"192.168.12.26\";ipv6=\"192:168:30::17\";active=\"yes\";preference=\"ipv4\";"</eNB_config_file>
<eNB_compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</eNB_compile_prog>
<eNB_compile_prog_args>--eNB -w USRP</eNB_compile_prog_args>
<eNB_compile_prog_args>--eNB -w USRP -x -c </eNB_compile_prog_args>
<eNB_pre_exec></eNB_pre_exec>
<eNB_pre_exec_args></eNB_pre_exec_args>
<eNB_main_exec>$OPENAIR_DIR/cmake_targets/lte_build_oai/build/lte-softmodem</eNB_main_exec>
<eNB_main_exec_args> -O $OPENAIR_DIR/targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.remote.conf </eNB_main_exec_args>
<eNB_traffic_exec>iperf -s</eNB_traffic_exec>
<eNB_traffic_exec></eNB_traffic_exec>
<eNB_traffic_exec_args></eNB_traffic_exec_args>
<eNB_search_expr_true></eNB_search_expr_true>
<eNB_search_expr_false></eNB_search_expr_false>
......@@ -780,12 +955,12 @@
targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.local.conf mobile_country_code \"5\"
targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.local.conf mobile_network_code \"6\"</UE_config_file>
<UE_compile_prog>$OPENAIR_DIR/cmake_targets/build_oai</UE_compile_prog>
<UE_compile_prog_args>--eNB -w USRP</UE_compile_prog_args>
<UE_compile_prog_args>--eNB -w USRP -x -c </UE_compile_prog_args>
<UE_pre_exec></UE_pre_exec>
<UE_pre_exec_args></UE_pre_exec_args>
<UE_main_exec>$OPENAIR_DIR/cmake_targets/autotests/tools/configure_cots_bandrich_ue.py --stop-ue ; $OPENAIR_DIR/cmake_targets/autotests/tools/configure_cots_bandrich_ue.py --start-ue </UE_main_exec>
<UE_main_exec>sleep 30 ; $OPENAIR_DIR/cmake_targets/autotests/tools/configure_cots_bandrich_ue.py --stop-ue ; $OPENAIR_DIR/cmake_targets/autotests/tools/configure_cots_bandrich_ue.py --start-ue </UE_main_exec>
<UE_main_exec_args></UE_main_exec_args>
<UE_traffic_exec>ping 192.172.0.1</UE_traffic_exec>
<UE_traffic_exec> while true; do var=`ifconfig ppp0` ;sleep 1; if [ "$var" != "" ]; then break; fi ; done ; sleep 5; iperf -u -c 192.172.0.1 -b 10Mbits/s -t 3000 -B 192.172.0.2</UE_traffic_exec>
<UE_traffic_exec_args></UE_traffic_exec_args>
<UE_search_expr_true></UE_search_expr_true>
<UE_search_expr_false></UE_search_expr_false>
......@@ -808,12 +983,12 @@
<EPC_main_exec_args></EPC_main_exec_args>
<HSS_main_exec>/opt/hss_sim0609/starthss >> /dev/null ; sleep 3000 </HSS_main_exec>
<HSS_main_exec_args></HSS_main_exec_args>
<EPC_traffic_exec>iperf -s</EPC_traffic_exec>
<EPC_traffic_exec>sleep 5; iperf -s -i 1 -u -f m -B 192.172.0.1</EPC_traffic_exec>
<EPC_traffic_exec_args></EPC_traffic_exec_args>
<EPC_search_expr_true></EPC_search_expr_true>
<EPC_search_expr_true>throughput_test min=0.0Mbits/sec max=0.0Mbits/sec average=0.0Mbits/sec duration=0.0s </EPC_search_expr_true>
<EPC_search_expr_false></EPC_search_expr_false>
<EPC_terminate_missing_procs>True</EPC_terminate_missing_procs>
<tags>USRP.ALU_EPC.Bandrich.5MHz.FDD.UL</tags>
<nruns>3</nruns>
</testCase>
......@@ -824,7 +999,6 @@
<eNB>calisson</eNB>
<UE>stevens</UE>
<EPC>nano</EPC>
<cleanupScript>oaisim* oaisim_nos1* lte-softmodem* lte-softmodem-nos1* mme_gw* run_epc* run_hss* iperf* ltebox*</cleanupScript>
<TimeOut_cmd>60</TimeOut_cmd>
<eNB_working_dir>/tmp</eNB_working_dir>
<eNB_config_file>targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.local.conf tracking_area_code \"1\"
......@@ -903,7 +1077,6 @@
<eNB>calisson</eNB>
<UE>stevens</UE>
<EPC>calisson</EPC>
<cleanupScript>oaisim* oaisim_nos1* lte-softmodem* lte-softmodem-nos1* mme_gw* run_epc* run_hss* iperf* ltebox*</cleanupScript>
<TimeOut_cmd>60</TimeOut_cmd>
<eNB_working_dir>/tmp</eNB_working_dir>
<eNB_config_file>targets/PROJECTS/GENERIC-LTE-EPC/CONF/enb.band7.tm1.usrpb210.epc.local.conf tracking_area_code \"1\"
......
......@@ -15,6 +15,11 @@ import os
#First we find an open port to work with
serial_port=''
ser=serial.Serial()
openair_dir = os.environ.get('OPENAIR_DIR')
if openair_dir == None:
print "Error getting OPENAIR_DIR environment variable"
sys.exit(1)
def find_open_port():
global serial_port, ser
max_ports=100
......@@ -33,7 +38,7 @@ find_open_port()
print 'Using Serial port : ' + serial_port
#serial_port = '/dev/ttyUSB2'
bandrich_ppd_config = '$OPENAIR_DIR/cmake_targets/autotests/tools/wdial.bandrich.conf'
bandrich_ppd_config = os.environ.get('OPENAIR_DIR') + '/cmake_targets/autotests/tools/wdial.bandrich.conf'
exit_flag=0
......@@ -103,7 +108,8 @@ def start_ue () :
#print 'Enter your commands below.\r\nInsert "exit" to leave the application.'
timeout=60 #timeout in seconds
send_command('AT', 'OK' , timeout)
send_command('AT+CGATT=0' , 'OK' , timeout)
send_command('AT+CFUN=1' , 'OK' , timeout)
#send_command('AT+CGATT=0' , 'OK' , timeout)
send_command('AT+CGATT=1','OK', 300)
#os.system('wvdial -C ' + bandrich_ppd_config + ' &' )
......@@ -121,6 +127,7 @@ def start_ue () :
ip = IPRoute()
idx = ip.link_lookup(ifname=iface)[0]
os.system ('route add 192.172.0.1 ppp0')
os.system ('ping 192.172.0.1')
break
except Exception, e:
error = ' Interface ' + iface + 'does not exist...'
......@@ -134,7 +141,8 @@ def stop_ue():
timeout=60
os.system('killall wvdial')
send_command('AT', 'OK' , timeout)
send_command('AT+CGATT=0' , 'OK' , timeout)
send_command('AT+CGATT=0' , 'OK|ERROR' , timeout)
send_command('AT+CFUN=4' , 'OK' , timeout)
for arg in sys.argv[1:]:
if arg == '--start-ue' :
......
......@@ -111,7 +111,12 @@ compilations() {
cd $OPENAIR_DIR/cmake_targets/$1/build
{
rm -f $3
if [ "$VERBOSE_COMPILE" == "1" ]; then
make -j`nproc` $2 VERBOSE=$VERBOSE_COMPILE
else
make -j`nproc` $2
fi
} > $dlog/$2.$REL.txt 2>&1
echo_info "Log file for compilation has been written to: $dlog/$2.$REL.txt"
if [ -s $3 ] ; then
......@@ -158,22 +163,33 @@ install_gnutls_from_source(){
check_install_usrp_uhd_driver(){
log_file=$OPENAIR_DIR/cmake_targets/log/check_install_usrp_uhd_driver_log.txt
echo_info "\nIn function: check_install_usrp_uhd_driver(). Installing USRP Drivers : The logfile for the installation is located here: $log_file "
(
v=$(lsb_release -cs)
$SUDO apt-add-repository "deb http://files.ettus.com/binaries/uhd/repo/uhd/ubuntu/$v $v main"
$SUDO apt-get update
$SUDO apt-get -y install python python-tk libboost-all-dev libusb-1.0-0-dev
$SUDO apt-get -y install -t `lsb_release -cs` uhd --force-yes
) >& $log_file
}
check_install_bladerf_driver(){
log_file=$OPENAIR_DIR/cmake_targets/log/check_install_bladerf_driver_log.txt
echo_info "\nIn function: check_install_bladerf_driver(). Install BLADERF drivers : The logfile for the installation is located here: $log_file "
(
$SUDO add-apt-repository -y ppa:bladerf/bladerf
$SUDO apt-get update
$SUDO apt-get install -y bladerf libbladerf-dev
$SUDO apt-get install bladerf-firmware-fx3
$SUDO apt-get install bladerf-fpga-hostedx40
$SUDO apt-get install -y bladerf-firmware-fx3
$SUDO apt-get install -y bladerf-fpga-hostedx40
bladeRF-cli --flash-firmware /usr/share/Nuand/bladeRF/bladeRF_fw.img
) >& $log_file
}
check_install_additional_tools (){
log_file=$OPENAIR_DIR/cmake_targets/log/check_install_additional_tools_log.txt
echo_info "\nIn function: check_install_oai_software(). Installing optional OAI packages : The logfile for the installation is located here: $log_file "
(
$SUDO apt-get update
$SUDO apt-get install -y \
check \
......@@ -194,11 +210,16 @@ check_install_additional_tools (){
unzip \
valgrind \
vlan \
ctags
ctags \
ntpdate
) >& $log_file
}
check_install_oai_software() {
log_file=$OPENAIR_DIR/cmake_targets/log/check_install_oai_software_log.txt
echo_info "\nIn function: check_install_oai_software(). Installing mandatory OAI packages : The logfile for the installation is located here: $log_file "
(
$SUDO apt-get update
$SUDO apt-get install -y \
autoconf \
......@@ -208,8 +229,8 @@ check_install_oai_software() {
cmake \
cmake-curses-gui \
doxygen \
doxygen-gui\
texlive-latex-base\
doxygen-gui \
texlive-latex-base \
ethtool \
flex \
gccxml \
......@@ -258,7 +279,8 @@ check_install_oai_software() {
xmlstarlet \
python-pip \
pydb \
wvdial
wvdial \
python-numpy
$SUDO update-alternatives --set liblapack.so /usr/lib/atlas-base/atlas/liblapack.so
if [ `lsb_release -rs` = '12.04' ] ; then
install_nettle_from_source
......@@ -268,20 +290,27 @@ check_install_oai_software() {
fi
$SUDO pip install paramiko
$SUDO pip install pyroute2
) > $log_file 2>&1
install_asn1c_from_source
$SUDO rm -fr /opt/ssh
$SUDO git clone https://gist.github.com/2190472.git /opt/ssh
}
install_asn1c_from_source(){
asn1_install_dir=$OPENAIR_DIR/cmake_targets/log/asn1c_install_log.txt
echo_info "\nInstalling ASN1. The log file for ASN1 installation is here: $asn1_install_dir "
(
rm -rf /tmp/asn1c-r1516
mkdir -p /tmp/asn1c-r1516
cd /tmp/asn1c-r1516
rm -rf /tmp/asn1c-r1516/*
svn co https://github.com/vlm/asn1c/trunk /tmp/asn1c-r1516 -r 1516 > /tmp/log_compile_asn1c
patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch.p0 >> /tmp/log_compile_asn1c
patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch_2.p0 >> /tmp/log_compile_asn1c
patch -p0 < $OPENAIR_DIR/openair2/RRC/LITE/MESSAGES/asn1c/asn1cpatch.p0 >> /tmp/log_compile_asn1c
svn co https://github.com/vlm/asn1c/trunk /tmp/asn1c-r1516 -r 1516
patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch.p0
patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch_2.p0
patch -p0 < $OPENAIR_DIR/openair2/RRC/LITE/MESSAGES/asn1c/asn1cpatch.p0
./configure
make > /tmp/log_compile_asn1c 2>&1
make -j`nproc`
$SUDO make install
) > $asn1_install_dir 2>&1
}
#################################################
......
......@@ -24,15 +24,18 @@ xUnit_start() {
# \param $1 classname
# \param $2 testcase name
# \param $3 testcase result
# \param $4 run index
# \param $4 run result
# \param $5 XML file local to test case for storing its own results
xUnit_fail() {
class=$1
test_case=$2
result=$3
run_index=$4
run_result=$4
xmlfile_testcase=$5
currtime=$(date +%s.%N)
time=$(echo "$currtime - $XUNIT_START" | bc -l)
xml="<testcase classname='$class' name='$test_case' run='$run_index' time='$time' RESULT='$result'></testcase>"
xml="<testcase classname='$class' name='$test_case' Run_result='$run_result' time='$time s' RESULT='$result'></testcase>"
echo -e $xml >> $xmlfile_testcase
XUNIT_TESTCASES_XML="$XUNIT_TESTCASES_XML \n$xml"
XUNIT_FAILED=$((XUNIT_FAILED+1))
}
......@@ -43,15 +46,18 @@ xUnit_fail() {
# \param $1 classname
# \param $2 testcase name
# \param $3 testcase result
# \param $4 run index
# \param $4 run result
# \param $5 XML file local to test case for storing its own results
xUnit_success() {
class=$1
test_case=$2
result=$3
run_index=$4
run_result=$4
xmlfile_testcase=$5
currtime=$(date +%s.%N)
time=$(echo "$currtime - $XUNIT_START" | bc -l)
xml="<testcase classname='$class' name='$test_case' run='$run_index' time='$time' RESULT='$result'></testcase>"
xml="<testcase classname='$class' name='$test_case' Run_result='$run_result' time='$time s' RESULT='$result'></testcase>"
echo -e $xml >> $xmlfile_testcase
XUNIT_TESTCASES_XML="$XUNIT_TESTCASES_XML \n$xml"
XUNIT_SUCCESS=$((XUNIT_SUCCESS+1))
}
......
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