cls_physim1.py 15 KB
Newer Older
Mohammed Ismail's avatar
Mohammed Ismail committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#/*
# * 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 logging
Mohammed Ismail's avatar
Mohammed Ismail committed
35
import sshconnection as SSH
Mohammed Ismail's avatar
Mohammed Ismail committed
36
37
import html
import os
Mohammed Ismail's avatar
Mohammed Ismail committed
38
39
40
import re
import time
import sys
Mohammed Ismail's avatar
Mohammed Ismail committed
41
42
43
44
45
46
47
48
import constants as CONST
import helpreadme as HELP

class PhySim:
	def __init__(self):
		self.eNBIpAddr = ""
		self.eNBUserName = ""
		self.eNBPassword = ""
Mohammed Ismail's avatar
Mohammed Ismail committed
49
50
		self.OCUserName = ""
		self.OCPassword = ""
Mohammed Ismail's avatar
Mohammed Ismail committed
51
		self.OCProjectName = ""
Mohammed Ismail's avatar
Mohammed Ismail committed
52
53
54
55
		self.eNBSourceCodePath = ""
		self.ranRepository = ""
		self.ranBranch = ""
		self.ranCommitID= ""
Mohammed Ismail's avatar
Mohammed Ismail committed
56
		self.ranAllowMerge= False
Mohammed Ismail's avatar
Mohammed Ismail committed
57
		self.ranTargetBranch= ""
Mohammed Ismail's avatar
Mohammed Ismail committed
58
59
60
		self.testResult = {}
		self.testCount = [0,0,0]
		self.testSummary = {}
61
		self.testStatus = False
Mohammed Ismail's avatar
Mohammed Ismail committed
62
63
64
65
66

#-----------------$
#PUBLIC Methods$
#-----------------$

67
	def Deploy_PhySim(self, HTML, RAN):
Mohammed Ismail's avatar
Mohammed Ismail committed
68
69
70
71
72
73
74
		if self.ranRepository == '' or self.ranBranch == '' or self.ranCommitID == '':
			HELP.GenericHelp(CONST.Version)
			sys.exit('Insufficient Parameter')
		lIpAddr = self.eNBIPAddress
		lUserName = self.eNBUserName
		lPassWord = self.eNBPassword
		lSourcePath = self.eNBSourceCodePath
Mohammed Ismail's avatar
Mohammed Ismail committed
75
76
		ocUserName = self.OCUserName
		ocPassword = self.OCPassword
Mohammed Ismail's avatar
Mohammed Ismail committed
77
		ocProjectName = self.OCProjectName
Mohammed Ismail's avatar
Mohammed Ismail committed
78

Mohammed Ismail's avatar
Mohammed Ismail committed
79
		if lIpAddr == '' or lUserName == '' or lPassWord == '' or lSourcePath == '' or ocUserName == '' or ocPassword == '' or ocProjectName == '':
Mohammed Ismail's avatar
Mohammed Ismail committed
80
81
82
83
84
85
86
87
88
89
90
			HELP.GenericHelp(CONST.Version)
			sys.exit('Insufficient Parameter')
		logging.debug('Building on server: ' + lIpAddr)
		mySSH = SSH.SSHConnection()
		mySSH.open(lIpAddr, lUserName, lPassWord)

		self.testCase_id = HTML.testCase_id

		# on RedHat/CentOS .git extension is mandatory
		result = re.search('([a-zA-Z0-9\:\-\.\/])+\.git', self.ranRepository)
		if result is not None:
91
			full_ran_repo_name = self.ranRepository.replace('git/', 'git')
Mohammed Ismail's avatar
Mohammed Ismail committed
92
93
		else:
			full_ran_repo_name = self.ranRepository + '.git'
94
		mySSH.command('echo ' + lPassWord + ' | sudo rm -Rf ' + lSourcePath, '\$', 30)
Mohammed Ismail's avatar
Mohammed Ismail committed
95
96
97
98
99
100
101
102
103
104
105
		mySSH.command('mkdir -p ' + lSourcePath, '\$', 5)
		mySSH.command('cd ' + lSourcePath, '\$', 5)
		mySSH.command('if [ ! -e .git ]; then stdbuf -o0 git clone ' + full_ran_repo_name + ' .; else stdbuf -o0 git fetch --prune; fi', '\$', 600)
		# Raphael: here add a check if git clone or git fetch went smoothly
		mySSH.command('git config user.email "jenkins@openairinterface.org"', '\$', 5)
		mySSH.command('git config user.name "OAI Jenkins"', '\$', 5)

		mySSH.command('echo ' + lPassWord + ' | sudo -S git clean -x -d -ff', '\$', 30)
		mySSH.command('mkdir -p cmake_targets/log', '\$', 5)
		# if the commit ID is provided use it to point to it
		if self.ranCommitID != '':
106
			mySSH.command('git checkout -f ' + self.ranCommitID, '\$', 30)
Mohammed Ismail's avatar
Mohammed Ismail committed
107
108
		if self.ranAllowMerge:
			imageTag = "ci-temp"
109
110
111
112
113
114
			if self.ranTargetBranch == '':
				if (self.ranBranch != 'develop') and (self.ranBranch != 'origin/develop'):
					mySSH.command('git merge --ff origin/develop -m "Temporary merge for CI"', '\$', 5)
			else:
				logging.debug('Merging with the target branch: ' + self.ranTargetBranch)
				mySSH.command('git merge --ff origin/' + self.ranTargetBranch + ' -m "Temporary merge for CI"', '\$', 5)
Mohammed Ismail's avatar
Mohammed Ismail committed
115
116
		else:
			imageTag = "develop"
Mohammed Ismail's avatar
Mohammed Ismail committed
117
		# Check if image is exist on the Red Hat server, before pushing it to OC cluster
Mohammed Ismail's avatar
Mohammed Ismail committed
118
		mySSH.command("sudo podman image inspect --format='Size = {{.Size}} bytes' oai-physim:" + imageTag, '\$', 60)
Mohammed Ismail's avatar
Mohammed Ismail committed
119
		if mySSH.getBefore().count('no such image') != 0:
Mohammed Ismail's avatar
Mohammed Ismail committed
120
			logging.error('\u001B[1m No such image oai-physim\u001B[0m')
121
			mySSH.close()
122
123
124
			HTML.CreateHtmlTestRow('N/A', 'KO', CONST.PHYSIM_IMAGE_ABSENT)
			RAN.prematureExit = True
			return
Mohammed Ismail's avatar
Mohammed Ismail committed
125
126
		else:
			result = re.search('Size *= *(?P<size>[0-9\-]+) *bytes', mySSH.getBefore())
Mohammed Ismail's avatar
Mohammed Ismail committed
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
			if result is not None:
				imageSize = float(result.group('size'))
				imageSize = imageSize / 1000
				if imageSize < 1000:
					logging.debug('\u001B[1m   oai-physim size is ' + ('%.0f' % imageSize) + ' kbytes\u001B[0m')
				else:
					imageSize = imageSize / 1000
					if imageSize < 1000:
						logging.debug('\u001B[1m   oai-physim size is ' + ('%.0f' % imageSize) + ' Mbytes\u001B[0m')
					else:
						imageSize = imageSize / 1000
						logging.debug('\u001B[1m   oai-physim is ' + ('%.3f' % imageSize) + ' Gbytes\u001B[0m')
			else:
				logging.debug('oai-physim size is unknown')

142
		# logging to OC Cluster and then switch to corresponding project
Mohammed Ismail's avatar
Mohammed Ismail committed
143
		mySSH.command(f'oc login -u {ocUserName} -p {ocPassword}', '\$', 6)
Mohammed Ismail's avatar
Mohammed Ismail committed
144
		if mySSH.getBefore().count('Login successful.') == 0:
Mohammed Ismail's avatar
Mohammed Ismail committed
145
			logging.error('\u001B[1m OC Cluster Login Failed\u001B[0m')
146
			mySSH.close()
147
148
149
			HTML.CreateHtmlTestRow('N/A', 'KO', CONST.OC_LOGIN_FAIL)
			RAN.prematureExit = True
			return
Mohammed Ismail's avatar
Mohammed Ismail committed
150
151
		else:
			logging.debug('\u001B[1m   Login to OC Cluster Successfully\u001B[0m')
Mohammed Ismail's avatar
Mohammed Ismail committed
152
153
154
		mySSH.command(f'oc project {ocProjectName}', '\$', 6)
		if mySSH.getBefore().count(f'Already on project "{ocProjectName}"') == 0 and mySSH.getBefore().count(f'Now using project "{self.OCProjectName}"') == 0:
			logging.error(f'\u001B[1m Unable to access OC project {ocProjectName}\u001B[0m')
155
			mySSH.close()
156
157
158
			HTML.CreateHtmlTestRow('N/A', 'KO', CONST.OC_PROJECT_FAIL)
			RAN.prematureExit = True
			return
Mohammed Ismail's avatar
Mohammed Ismail committed
159
		else:
Mohammed Ismail's avatar
Mohammed Ismail committed
160
			logging.debug(f'\u001B[1m   Now using project {ocProjectName}\u001B[0m')
Mohammed Ismail's avatar
Mohammed Ismail committed
161
162
163
164
165

		# Tag the image and push to the OC cluster
		mySSH.command('oc whoami -t | sudo podman login -u ' + ocUserName + ' --password-stdin https://default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/ --tls-verify=false', '\$', 6)
		if mySSH.getBefore().count('Login Succeeded!') == 0:
			logging.error('\u001B[1m Podman Login to OC Cluster Registry Failed\u001B[0m')
166
			mySSH.close()
167
168
169
			HTML.CreateHtmlTestRow('N/A', 'KO', CONST.OC_LOGIN_FAIL)
			RAN.prematureExit = True
			return
Mohammed Ismail's avatar
Mohammed Ismail committed
170
171
		else:
			logging.debug('\u001B[1m Podman Login to OC Cluster Registry Successfully\u001B[0m')
172
		time.sleep(2)
173
174
		mySSH.command('oc create -f openshift/oai-physim-image-stream.yml', '\$', 6)
		if mySSH.getBefore().count('(AlreadyExists):') == 0 and mySSH.getBefore().count('created') == 0:
Mohammed Ismail's avatar
Mohammed Ismail committed
175
			logging.error(f'\u001B[1m Image Stream "oai-physim" Creation Failed on OC Cluster {ocProjectName}\u001B[0m')
176
			mySSH.close()
177
178
179
			HTML.CreateHtmlTestRow('N/A', 'KO', CONST.OC_IS_FAIL)
			RAN.prematureExit = True
			return
180
		else:
Mohammed Ismail's avatar
Mohammed Ismail committed
181
			logging.debug(f'\u001B[1m   Image Stream "oai-physim" created on OC project {ocProjectName}\u001B[0m')
182
		time.sleep(2)
Mohammed Ismail's avatar
Mohammed Ismail committed
183
		mySSH.command(f'sudo podman tag oai-physim:{imageTag} default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/{self.OCProjectName}/oai-physim:{imageTag}', '\$', 6)
184
		time.sleep(2)
Mohammed Ismail's avatar
Mohammed Ismail committed
185
		mySSH.command(f'sudo podman push default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/{self.OCProjectName}/oai-physim:{imageTag} --tls-verify=false', '\$', 30)
Mohammed Ismail's avatar
Mohammed Ismail committed
186
187
		if mySSH.getBefore().count('Storing signatures') == 0:
			logging.error('\u001B[1m Image "oai-physim" push to OC Cluster Registry Failed\u001B[0m')
188
			mySSH.close()
189
190
191
			HTML.CreateHtmlTestRow('N/A', 'KO', CONST.OC_IS_FAIL)
			RAN.prematureExit = True
			return
Mohammed Ismail's avatar
Mohammed Ismail committed
192
193
194
		else:
			logging.debug('\u001B[1m Image "oai-physim" push to OC Cluster Registry Successfully\u001B[0m')

Mohammed Ismail's avatar
Mohammed Ismail committed
195
		# Using helm charts deployment
196
		time.sleep(5)
Mohammed Ismail's avatar
Mohammed Ismail committed
197
		mySSH.command(f'sed -i -e "s#TAG#{imageTag}#g" ./charts/physims/values.yaml', '\$', 6)
Mohammed Ismail's avatar
Mohammed Ismail committed
198
		mySSH.command('helm install physim ./charts/physims/ | tee -a cmake_targets/log/physim_helm_summary.txt 2>&1', '\$', 6)
Mohammed Ismail's avatar
Mohammed Ismail committed
199
		if mySSH.getBefore().count('STATUS: deployed') == 0:
Mohammed Ismail's avatar
Mohammed Ismail committed
200
201
			logging.error('\u001B[1m Deploying PhySim Failed using helm chart on OC Cluster\u001B[0m')
			mySSH.command('helm uninstall physim >> cmake_targets/log/physim_helm_summary.txt 2>&1', '\$', 6)
202
203
204
205
206
207
208
209
			isFinished1 = False
			while(isFinished1 == False):
				time.sleep(20)
				mySSH.command('oc get pods -l app.kubernetes.io/instance=physim', '\$', 6, resync=True)
				if re.search('No resources found', mySSH.getBefore()):
					isFinished1 = True
			mySSH.command(f'sudo podman rmi default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/{self.OCProjectName}/oai-physim:{imageTag}', '\$', 6)
			mySSH.command('oc delete is oai-physim', '\$', 6)
210
			mySSH.close()
Mohammed Ismail's avatar
Mohammed Ismail committed
211
			self.AnalyzeLogFile_phySim(HTML)
212
213
			RAN.prematureExit = True
			return
Mohammed Ismail's avatar
Mohammed Ismail committed
214
215
216
		else:
			logging.debug('\u001B[1m   Deployed PhySim Successfully using helm chart\u001B[0m')
		isRunning = False
Mohammed Ismail's avatar
Mohammed Ismail committed
217
218
219
		count = 0
		while(count < 2 and isRunning == False):
			time.sleep(60)
220
			mySSH.command('oc get pods -o wide -l app.kubernetes.io/instance=physim | tee -a cmake_targets/log/physim_pods_summary.txt', '\$', 6, resync=True)
Mohammed Ismail's avatar
Mohammed Ismail committed
221
222
223
			if mySSH.getBefore().count('Running') == 12:
				logging.debug('\u001B[1m Running the physim test Scenarios\u001B[0m')
				isRunning = True
224
				podNames = re.findall('oai-[\S\d\w]+', mySSH.getBefore())
Mohammed Ismail's avatar
Mohammed Ismail committed
225
226
227
			count +=1
		if isRunning == False:
			logging.error('\u001B[1m Some PODS Running FAILED \u001B[0m')
228
			mySSH.command('oc get pods -l app.kubernetes.io/instance=physim 2>&1 | tee -a cmake_targets/log/physim_pods_summary.txt', '\$', 6)
Mohammed Ismail's avatar
Mohammed Ismail committed
229
230
			mySSH.command('helm uninstall physim >> cmake_targets/log/physim_helm_summary.txt 2>&1', '\$', 6)
			self.AnalyzeLogFile_phySim(HTML)
231
232
233
234
235
236
237
238
239
240
241
242
			isFinished1 = False
			while(isFinished1 == False):
				time.sleep(20)
				mySSH.command('oc get pods -l app.kubernetes.io/instance=physim', '\$', 6, resync=True)
				if re.search('No resources found', mySSH.getBefore()):
					isFinished1 = True
			mySSH.command(f'sudo podman rmi default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/{self.OCProjectName}/oai-physim:{imageTag}', '\$', 6)
			mySSH.command('oc delete is oai-physim', '\$', 6)
			HTML.CreateHtmlTestRow('N/A', 'KO', CONST.OC_PHYSIM_DEPLOY_FAIL)
			HTML.CreateHtmlTestRowPhySimTestResult(self.testSummary,self.testResult)
			RAN.prematureExit = True
			return
Mohammed Ismail's avatar
Mohammed Ismail committed
243
		# Waiting to complete the running test
Mohammed Ismail's avatar
Mohammed Ismail committed
244
245
		count = 0
		isFinished = False
246
247
		# doing a deep copy!
		tmpPodNames = podNames.copy()
248
		while(count < 32 and isFinished == False):
249
			time.sleep(60)
Mohammed Ismail's avatar
Mohammed Ismail committed
250
			for podName in tmpPodNames:
251
252
				mySSH.command2(f'oc logs --tail=1 {podName} 2>&1', 6, silent=True)
				if mySSH.cmd2Results.count('FINISHED') != 0:
253
					logging.debug(podName + ' is finished')
Mohammed Ismail's avatar
Mohammed Ismail committed
254
255
					tmpPodNames.remove(podName)
			if not tmpPodNames:
Mohammed Ismail's avatar
Mohammed Ismail committed
256
				isFinished = True
Mohammed Ismail's avatar
Mohammed Ismail committed
257
258
259
			count += 1
		if isFinished:
			logging.debug('\u001B[1m PhySim test is Complete\u001B[0m')
260
261
		else:
			logging.error('\u001B[1m PhySim test Timed-out!\u001B[0m')
262

Mohammed Ismail's avatar
Mohammed Ismail committed
263
264
		# Getting the logs of each executables running in individual pods
		for podName in podNames:
265
			mySSH.command(f'oc logs {podName} >> cmake_targets/log/physim_test.txt 2>&1', '\$', 15, resync=True)
Mohammed Ismail's avatar
Mohammed Ismail committed
266
		time.sleep(30)
Mohammed Ismail's avatar
Mohammed Ismail committed
267

Mohammed Ismail's avatar
Mohammed Ismail committed
268
		# UnDeploy the physical simulator pods
Mohammed Ismail's avatar
Mohammed Ismail committed
269
		mySSH.command('helm uninstall physim | tee -a cmake_targets/log/physim_helm_summary.txt 2>&1', '\$', 6)
270
271
		isFinished1 = False
		while(isFinished1 == False):
272
			time.sleep(20)
273
			mySSH.command('oc get pods -l app.kubernetes.io/instance=physim', '\$', 6, resync=True)
274
275
276
			if re.search('No resources found', mySSH.getBefore()):
				isFinished1 = True
		if isFinished1 == True:
Mohammed Ismail's avatar
Mohammed Ismail committed
277
			logging.debug('\u001B[1m UnDeployed PhySim Successfully on OC Cluster\u001B[0m')
Mohammed Ismail's avatar
Mohammed Ismail committed
278
		mySSH.command(f'sudo podman rmi default-route-openshift-image-registry.apps.5glab.nsa.eurecom.fr/{self.OCProjectName}/oai-physim:{imageTag}', '\$', 6)
Mohammed Ismail's avatar
Mohammed Ismail committed
279
280
		mySSH.command('oc delete is oai-physim', '\$', 6)
		logging.debug('\u001B[1m Deleted the Image and ImageStream\u001B[0m')
Mohammed Ismail's avatar
Mohammed Ismail committed
281
282
283
		mySSH.command('oc logout', '\$', 6)
		mySSH.close()
		self.AnalyzeLogFile_phySim(HTML)
284
		if self.testStatus and isFinished:
285
286
287
288
289
			HTML.CreateHtmlTestRow('N/A', 'OK', CONST.ALL_PROCESSES_OK)
			HTML.CreateHtmlTestRowPhySimTestResult(self.testSummary,self.testResult)
			logging.info('\u001B[1m Physical Simulator Pass\u001B[0m')
		else:
			RAN.prematureExit = True
290
291
292
293
			if isFinished:
				HTML.CreateHtmlTestRow('N/A', 'KO', CONST.ALL_PROCESSES_OK)
			else:
				HTML.CreateHtmlTestRow('Some test(s) timed-out!', 'KO', CONST.ALL_PROCESSES_OK)
294
			HTML.CreateHtmlTestRowPhySimTestResult(self.testSummary,self.testResult)
295
			logging.error('\u001B[1m Physical Simulator Fail\u001B[0m')
Mohammed Ismail's avatar
Mohammed Ismail committed
296
297
298
299
300
301
302
303
304
305
306

	def AnalyzeLogFile_phySim(self, HTML):
		lIpAddr = self.eNBIPAddress
		lUserName = self.eNBUserName
		lPassWord = self.eNBPassword
		lSourcePath = self.eNBSourceCodePath
		mySSH = SSH.SSHConnection()
		mySSH.open(lIpAddr, lUserName, lPassWord)
		mySSH.command('cd ' + lSourcePath, '\$', 5)
		mySSH.command('cd ' + lSourcePath + '/cmake_targets', '\$', 5)
		mySSH.command('mkdir -p physim_test_log_' + self.testCase_id, '\$', 5)
307
		mySSH.command('cp log/physim_* ' + 'physim_test_log_' + self.testCase_id, '\$', 5)
Mohammed Ismail's avatar
Mohammed Ismail committed
308
309
310
311
		if not os.path.exists(f'./physim_test_logs_{self.testCase_id}'):
			os.mkdir(f'./physim_test_logs_{self.testCase_id}')
		mySSH.copyin(lIpAddr, lUserName, lPassWord, lSourcePath + '/cmake_targets/physim_test_log_' + self.testCase_id + '/*', './physim_test_logs_' + self.testCase_id)
		mySSH.command('rm -rf ./physim_test_log_'+ self.testCase_id, '\$', 5)
Mohammed Ismail's avatar
Mohammed Ismail committed
312
		mySSH.close()
Mohammed Ismail's avatar
Mohammed Ismail committed
313
314
315
316
		# physim test log analysis
		nextt = 0
		if (os.path.isfile(f'./physim_test_logs_{self.testCase_id}/physim_test.txt')):
			with open(f'./physim_test_logs_{self.testCase_id}/physim_test.txt', 'r') as logfile:
Mohammed Ismail's avatar
Mohammed Ismail committed
317
				for line in logfile:
Mohammed Ismail's avatar
Mohammed Ismail committed
318
319
320
321
322
323
324
325
					if re.search('execution 015', str(line)) or re.search('Bypassing compilation', str(line)):
						nextt = 1
					elif nextt == 1:
						if not re.search('Test Results', str(line)):
							nextt = 0
							ret2 = re.search('T[^\n]*', str(line))
							if ret2 is not None:
								ret3 = ret2.group()
Mohammed Ismail's avatar
Mohammed Ismail committed
326
								ret3 = ret3.replace("", "")
Mohammed Ismail's avatar
Mohammed Ismail committed
327
328
					if re.search('execution 015', str(line)):
						self.testCount[0] += 1
Mohammed Ismail's avatar
Mohammed Ismail committed
329
330
331
						testName = line.split()
						ret1 = re.search('Result = PASS', str(line))
						if ret1 is not None:
Mohammed Ismail's avatar
Mohammed Ismail committed
332
333
							self.testResult[testName[1]] = [ret3, 'PASS']
							self.testCount[1] += 1
Mohammed Ismail's avatar
Mohammed Ismail committed
334
						else:
Mohammed Ismail's avatar
Mohammed Ismail committed
335
							self.testResult[testName[1]] = [ret3, 'FAIL']
336
							self.testCount[2] += 1
Mohammed Ismail's avatar
Mohammed Ismail committed
337
338
339
		self.testSummary['Nbtests'] = self.testCount[0]
		self.testSummary['Nbpass'] =  self.testCount[1]
		self.testSummary['Nbfail'] =  self.testCount[2]
340
341
		if self.testSummary['Nbfail'] == 0:
			self.testStatus = True
Mohammed Ismail's avatar
Mohammed Ismail committed
342
		return 0