Commit d85dea46 authored by Xiaowu Zhang's avatar Xiaowu Zhang

erp5_test_result: fix getIntIndex attribute error for Scalability Test

Suite

Module erp5.component.document.erp5_version.ERP5ProjectUnitTestDistributor, line 326, in getTestSuiteSortKey
  wanted_test_core_quantity = PRIORITY_MAPPING[test_suite.getIntIndex()][1]
AttributeError: getIntIndex
parent 15f57dfb
Pipeline #16840 failed with stage
in 0 seconds
...@@ -21,6 +21,7 @@ ...@@ -21,6 +21,7 @@
<portal_type id="Scalability Test Suite"> <portal_type id="Scalability Test Suite">
<item>Arrow</item> <item>Arrow</item>
<item>ScalabilityTestSuite</item> <item>ScalabilityTestSuite</item>
<item>SortIndex</item>
<item>TestSuite</item> <item>TestSuite</item>
</portal_type> </portal_type>
<portal_type id="SlapOS Agent Distributor"> <portal_type id="SlapOS Agent Distributor">
......
...@@ -1262,6 +1262,24 @@ class TestTaskDistribution(TaskDistributionTestCase): ...@@ -1262,6 +1262,24 @@ class TestTaskDistribution(TaskDistributionTestCase):
for suite in config_nodes.values(): for suite in config_nodes.values():
self.assertEquals(suite, []) self.assertEquals(suite, [])
def test_16A_startTestSuiteERP5ScalabilityDistributorWithRunningTestResult(self):
# Subscribe nodes
self.scalability_distributor.subscribeNode("COMP1-Scalability-Node1", computer_guid="COMP-1")
# Create test suite
test_suite = self._createTestSuite(quantity=1,priority=1, reference_correction=0,
specialise_value=self.scalability_distributor, portal_type="Scalability Test Suite")[0]
self.tic()
self._callOptimizeAlarm()
test_result = self.test_result_module.newContent(
portal_type = 'Test Result',
title = test_suite.getTitle()
)
test_result.start()
self.tic()
configuration = self.scalability_distributor.startTestSuite(title="COMP1-Scalability-Node1")
self.assertNotEquals(configuration, [])
def test_17_isMasterTestnodeERP5ScalabilityDistributor(self): def test_17_isMasterTestnodeERP5ScalabilityDistributor(self):
""" """
Check the method isMasterTestnode() Check the method isMasterTestnode()
......
...@@ -9,6 +9,7 @@ Gitlab REST Connector | Reference ...@@ -9,6 +9,7 @@ Gitlab REST Connector | Reference
Gitlab REST Connector | Url Gitlab REST Connector | Url
Scalability Test Suite | Arrow Scalability Test Suite | Arrow
Scalability Test Suite | ScalabilityTestSuite Scalability Test Suite | ScalabilityTestSuite
Scalability Test Suite | SortIndex
Scalability Test Suite | TestSuite Scalability Test Suite | TestSuite
SlapOS Agent Distributor | ScalabilityDistributor SlapOS Agent Distributor | ScalabilityDistributor
SlapOS Agent Test Suite | Arrow SlapOS Agent Test Suite | Arrow
......
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