Commit c286b2a9 authored by Gabriele Perrone's avatar Gabriele Perrone

to switch to develop

parent 70633682
# * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
# * contributor license agreements. See the NOTICE file distributed with
# * this work for additional information regarding copyright ownership.
# * The OpenAirInterface Software Alliance licenses this file to You under
# * the OAI Public License, Version 1.1 (the "License"); you may not use this file
# * except in compliance with the License.
# * You may obtain a copy of the License at
# *
# * http://www.openairinterface.org/?page_id=698
# *
# * Unless required by applicable law or agreed to in writing, software
# * distributed under the License is distributed on an "AS IS" BASIS,
# * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# * See the License for the specific language governing permissions and
# * limitations under the License.
# *-------------------------------------------------------------------------------
# * For more information about the OpenAirInterface (OAI) Software Alliance:
# * contact@openairinterface.org
# */
#---------------------------------------------------------------------
# Python for CI of OAI-eNB + COTS-UE
#
# Required Python Version
# Python 3.x
#
# Required Python Package
# pexpect
#---------------------------------------------------------------------
#----------------------------------------------------------- #-----------------------------------------------------------
# Import # Import
#----------------------------------------------------------- #-----------------------------------------------------------
...@@ -14,22 +44,28 @@ from multiprocessing import Process, Lock, SimpleQueue ...@@ -14,22 +44,28 @@ from multiprocessing import Process, Lock, SimpleQueue
# OAI Testing modules # OAI Testing modules
#----------------------------------------------------------- #-----------------------------------------------------------
import sshconnection as SSH import sshconnection as SSH
#from sshconnection import SSHConnection as SSH
import helpreadme as HELP import helpreadme as HELP
import constants as CONST import constants as CONST
import html as HTML
#----------------------------------------------------------- #-----------------------------------------------------------
# Class Declaration # Class Declaration
#----------------------------------------------------------- #-----------------------------------------------------------
class EPCManagement(): class EPCManagement():
def __init__(self): def __init__(self):
self.EPCIPAddress = ''
self.EPCUserName = '' self.IPAddress = ''
self.EPCPassword = '' self.UserName = ''
self.EPCSourceCodePath = '' self.Password = ''
self.EPCType = '' self.SourceCodePath = ''
self.Type = ''
self.EPC_PcapFileName = '' self.EPC_PcapFileName = ''
#-----------------------------------------------------------
# Setter and Getters
#-----------------------------------------------------------
def SetIPAddress(self, ipaddress): def SetIPAddress(self, ipaddress):
self.EPCIPAddress = ipaddress self.EPCIPAddress = ipaddress
def GetIPAddress(self): def GetIPAddress(self):
...@@ -55,6 +91,10 @@ class EPCManagement(): ...@@ -55,6 +91,10 @@ class EPCManagement():
def Get_PcapFileName(self): def Get_PcapFileName(self):
return self.EPC_PcapFileName return self.EPC_PcapFileName
#-----------------------------------------------------------
# EPC management functions
#-----------------------------------------------------------
def InitializeHSS(self): def InitializeHSS(self):
if self.EPCIPAddress == '' or self.EPCUserName == '' or self.EPCPassword == '' or self.EPCSourceCodePath == '' or self.EPCType == '': if self.EPCIPAddress == '' or self.EPCUserName == '' or self.EPCPassword == '' or self.EPCSourceCodePath == '' or self.EPCType == '':
HELP.GenericHelp(Version) HELP.GenericHelp(Version)
...@@ -91,7 +131,7 @@ class EPCManagement(): ...@@ -91,7 +131,7 @@ class EPCManagement():
else: else:
logging.error('This option should not occur!') logging.error('This option should not occur!')
mySSH.close() mySSH.close()
#self.CreateHtmlTestRow(self.EPCType, 'OK', CONST.ALL_PROCESSES_OK) HTML.CreateHtmlTestRow(self.EPCType, 'OK', CONST.ALL_PROCESSES_OK)
def InitializeMME(self): def InitializeMME(self):
if self.EPCIPAddress == '' or self.EPCUserName == '' or self.EPCPassword == '' or self.EPCSourceCodePath == '' or self.EPCType == '': if self.EPCIPAddress == '' or self.EPCUserName == '' or self.EPCPassword == '' or self.EPCSourceCodePath == '' or self.EPCType == '':
...@@ -124,7 +164,7 @@ class EPCManagement(): ...@@ -124,7 +164,7 @@ class EPCManagement():
else: else:
logging.error('This option should not occur!') logging.error('This option should not occur!')
mySSH.close() mySSH.close()
#self.CreateHtmlTestRow(self.EPCType, 'OK', ALL_PROCESSES_OK) HTML.CreateHtmlTestRow(self.EPCType, 'OK', ALL_PROCESSES_OK)
def InitializeSPGW(self): def InitializeSPGW(self):
if self.EPCIPAddress == '' or self.EPCUserName == '' or self.EPCPassword == '' or self.EPCSourceCodePath == '' or self.EPCType == '': if self.EPCIPAddress == '' or self.EPCUserName == '' or self.EPCPassword == '' or self.EPCSourceCodePath == '' or self.EPCType == '':
...@@ -155,7 +195,7 @@ class EPCManagement(): ...@@ -155,7 +195,7 @@ class EPCManagement():
else: else:
logging.error('This option should not occur!') logging.error('This option should not occur!')
mySSH.close() mySSH.close()
#self.CreateHtmlTestRow(self.EPCType, 'OK', ALL_PROCESSES_OK) HTML.CreateHtmlTestRow(self.EPCType, 'OK', ALL_PROCESSES_OK)
def CheckHSSProcess(self, status_queue): def CheckHSSProcess(self, status_queue):
...@@ -255,7 +295,7 @@ class EPCManagement(): ...@@ -255,7 +295,7 @@ class EPCManagement():
else: else:
logging.error('This should not happen!') logging.error('This should not happen!')
mySSH.close() mySSH.close()
#self.CreateHtmlTestRow('N/A', 'OK', CONST.ALL_PROCESSES_OK) HTML.CreateHtmlTestRow('N/A', 'OK', CONST.ALL_PROCESSES_OK)
def TerminateMME(self): def TerminateMME(self):
mySSH = SSH.SSHConnection() mySSH = SSH.SSHConnection()
...@@ -274,7 +314,7 @@ class EPCManagement(): ...@@ -274,7 +314,7 @@ class EPCManagement():
else: else:
logging.error('This should not happen!') logging.error('This should not happen!')
mySSH.close() mySSH.close()
#self.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK) HTML.CreateHtmlTestRow('N/A', 'OK', ALL_PROCESSES_OK)
def TerminateSPGW(self): def TerminateSPGW(self):
mySSH = SSH.SSHConnection() mySSH = SSH.SSHConnection()
...@@ -305,7 +345,7 @@ class EPCManagement(): ...@@ -305,7 +345,7 @@ class EPCManagement():
else: else:
logging.error('This should not happen!') logging.error('This should not happen!')
mySSH.close() mySSH.close()
#self.CreateHtmlTestRow('N/A', 'OK', CONST.ALL_PROCESSES_OK) HTML.CreateHtmlTestRow('N/A', 'OK', CONST.ALL_PROCESSES_OK)
def LogCollectHSS(self): def LogCollectHSS(self):
......
# * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
# * contributor license agreements. See the NOTICE file distributed with
# * this work for additional information regarding copyright ownership.
# * The OpenAirInterface Software Alliance licenses this file to You under
# * the OAI Public License, Version 1.1 (the "License"); you may not use this file
# * except in compliance with the License.
# * You may obtain a copy of the License at
# *
# * http://www.openairinterface.org/?page_id=698
# *
# * Unless required by applicable law or agreed to in writing, software
# * distributed under the License is distributed on an "AS IS" BASIS,
# * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# * See the License for the specific language governing permissions and
# * limitations under the License.
# *-------------------------------------------------------------------------------
# * For more information about the OpenAirInterface (OAI) Software Alliance:
# * contact@openairinterface.org
# */
#---------------------------------------------------------------------
# Python for CI of OAI-eNB + COTS-UE
#
# Required Python Version
# Python 3.x
#
# Required Python Package
# pexpect
#---------------------------------------------------------------------
#----------------------------------------------------------- #-----------------------------------------------------------
# Functions Declaration # Functions Declaration
#----------------------------------------------------------- #-----------------------------------------------------------
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
# * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
# * contributor license agreements. See the NOTICE file distributed with
# * this work for additional information regarding copyright ownership.
# * The OpenAirInterface Software Alliance licenses this file to You under
# * the OAI Public License, Version 1.1 (the "License"); you may not use this file
# * except in compliance with the License.
# * You may obtain a copy of the License at
# *
# * http://www.openairinterface.org/?page_id=698
# *
# * Unless required by applicable law or agreed to in writing, software
# * distributed under the License is distributed on an "AS IS" BASIS,
# * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# * See the License for the specific language governing permissions and
# * limitations under the License.
# *-------------------------------------------------------------------------------
# * For more information about the OpenAirInterface (OAI) Software Alliance:
# * contact@openairinterface.org
# */
#---------------------------------------------------------------------
# Python for CI of OAI-eNB + COTS-UE
#
# Required Python Version
# Python 3.x
#
# Required Python Package
# pexpect
#---------------------------------------------------------------------
#----------------------------------------------------------- #-----------------------------------------------------------
# Import # Import
#----------------------------------------------------------- #-----------------------------------------------------------
......
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