diff --git a/ci-scripts/cls_oai_html.py b/ci-scripts/cls_oai_html.py index 04971485a6..b927373124 100644 --- a/ci-scripts/cls_oai_html.py +++ b/ci-scripts/cls_oai_html.py @@ -65,10 +65,6 @@ class HTMLManagement(): self.htmlTabIcons = [] self.testXMLfiles = [] - self.testUnstable = False - self.testMinStableId = '999999' - self.testStabilityPointReached = False - self.htmleNBFailureMsg = '' self.htmlUEFailureMsg = '' @@ -219,20 +215,13 @@ class HTMLManagement(): def CreateHtmlTabFooter(self, passStatus): if ((not self.htmlFooterCreated) and (self.htmlHeaderCreated)): - testOkEvenIfUnstable = False - if self.testUnstable and not passStatus: - if self.testStabilityPointReached or self.testMinStableId == '999999': - testOkEvenIfUnstable = True self.htmlFile = open('test_results.html', 'a') self.htmlFile.write(' \n') self.htmlFile.write(' Final Tab Status\n') if passStatus: self.htmlFile.write(' PASS \n') else: - if testOkEvenIfUnstable: - self.htmlFile.write(' KNOWN UNSTABLE SCENARIO \n') - else: - self.htmlFile.write(' FAIL \n') + self.htmlFile.write(' FAIL \n') self.htmlFile.write(' \n') self.htmlFile.write(' \n') self.htmlFile.write(' \n') @@ -242,10 +231,7 @@ class HTMLManagement(): cmd = "sed -i -e 's/__STATE_" + self.htmlTabNames[0] + "__//' test_results.html" subprocess.run(cmd, shell=True) else: - if testOkEvenIfUnstable: - cmd = "sed -i -e 's/__STATE_" + self.htmlTabNames[0] + "__/<\/span>/' test_results.html" - else: - cmd = "sed -i -e 's/__STATE_" + self.htmlTabNames[0] + "__/<\/span>/' test_results.html" + cmd = "sed -i -e 's/__STATE_" + self.htmlTabNames[0] + "__/<\/span>/' test_results.html" subprocess.run(cmd, shell=True) self.htmlFooterCreated = False diff --git a/ci-scripts/cls_oaicitest.py b/ci-scripts/cls_oaicitest.py index 2dbc24828d..2c78779e24 100644 --- a/ci-scripts/cls_oaicitest.py +++ b/ci-scripts/cls_oaicitest.py @@ -235,9 +235,6 @@ class OaiCiTest(): self.FailReportCnt = 0 self.testCase_id = '' self.testXMLfiles = [] - self.testUnstable = False - self.testMinStableId = '999999' - self.testStabilityPointReached = False self.desc = '' self.ping_args = '' self.ping_packetloss_threshold = '' @@ -975,12 +972,6 @@ class OaiCiTest(): SSH.command(f'echo {self.UEPassword} | sudo -S rm ue*.log core* ue_*record.raw ue_*.pcap ue_*txt', '\$', 5) SSH.close() - def ConditionalExit(self): - if self.testUnstable: - if self.testStabilityPointReached or self.testMinStableId == '999999': - sys.exit(0) - sys.exit(1) - def ShowTestID(self): logging.info(f'\u001B[1m----------------------------------------\u001B[0m') logging.info(f'\u001B[1m Test ID: {self.testCase_id} \u001B[0m') diff --git a/ci-scripts/main.py b/ci-scripts/main.py index 0e54401b7b..ea3963fbca 100644 --- a/ci-scripts/main.py +++ b/ci-scripts/main.py @@ -596,14 +596,7 @@ elif re.match('^TesteNB$', mode, re.IGNORECASE) or re.match('^TestUE$', mode, re HTML.htmlTabRefs.append(xmlRoot.findtext('htmlTabRef',default='test-tab-0')) HTML.htmlTabNames.append(xmlRoot.findtext('htmlTabName',default='Test-0')) repeatCount = xmlRoot.findtext('repeatCount',default='1') - testStability = xmlRoot.findtext('TestUnstable',default='False') CiTestObj.repeatCounts.append(int(repeatCount)) - if testStability == 'True': - CiTestObj.testUnstable = True - HTML.testUnstable = True - CiTestObj.testMinStableId = xmlRoot.findtext('TestMinId',default='999999') - HTML.testMinStableId = CiTestObj.testMinStableId - logging.warning('Test is tagged as Unstable -- starting from TestID ' + str(CiTestObj.testMinStableId)) all_tests=xmlRoot.findall('testCase') exclusion_tests=exclusion_tests.split() @@ -829,20 +822,11 @@ elif re.match('^TesteNB$', mode, re.IGNORECASE) or re.match('^TestUE$', mode, re logging.error(f'while running CI, an exception occurred:\n{s}') HTML.CreateHtmlTestRowQueue("N/A", 'KO', [f"CI test code encountered an exception:\n{s}"]) RAN.prematureExit = True - - if RAN.prematureExit: - if CiTestObj.testCase_id == CiTestObj.testMinStableId: - logging.warning('Scenario has reached minimal stability point') - CiTestObj.testStabilityPointReached = True - HTML.testStabilityPointReached = True CiTestObj.FailReportCnt += 1 if CiTestObj.FailReportCnt == CiTestObj.repeatCounts[0] and RAN.prematureExit: logging.error('\u001B[1;37;41mScenario failed ' + str(CiTestObj.FailReportCnt) + ' time(s)\u001B[0m') HTML.CreateHtmlTabFooter(False) - if CiTestObj.testUnstable and (CiTestObj.testStabilityPointReached or CiTestObj.testMinStableId == '999999'): - logging.warning('\u001B[1;30;43mScenario has reached minimal stability point -- Not a Failure\u001B[0m') - else: - sys.exit('Failed Scenario') + sys.exit('Failed Scenario') else: logging.info('\u001B[1;37;42mScenario passed after ' + str(CiTestObj.FailReportCnt) + ' time(s)\u001B[0m') HTML.CreateHtmlTabFooter(True)