Commit 076cb084 authored by Romain Courteaud's avatar Romain Courteaud

Pass portal_type as parameter of newCell, as multiple portal types may be allowed in the container.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@13298 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 1dbf92ee
...@@ -56,7 +56,7 @@ from Products.ERP5Type import product_path ...@@ -56,7 +56,7 @@ from Products.ERP5Type import product_path
from Products.CMFCore.utils import getToolByName from Products.CMFCore.utils import getToolByName
from testOrder import TestOrderMixin from testOrder import TestOrderMixin
class TestTransformation(TestOrderMixin,ERP5TypeTestCase): class TestTransformation(TestOrderMixin, ERP5TypeTestCase):
""" """
Test Transformations Test Transformations
""" """
...@@ -84,7 +84,6 @@ class TestTransformation(TestOrderMixin,ERP5TypeTestCase): ...@@ -84,7 +84,6 @@ class TestTransformation(TestOrderMixin,ERP5TypeTestCase):
""" """
return 1 return 1
def stepCreateComponentDict(self, sequence=None, sequence_list=None, \ def stepCreateComponentDict(self, sequence=None, sequence_list=None, \
**kw): **kw):
""" """
...@@ -101,7 +100,7 @@ class TestTransformation(TestOrderMixin,ERP5TypeTestCase): ...@@ -101,7 +100,7 @@ class TestTransformation(TestOrderMixin,ERP5TypeTestCase):
component_dict = {} component_dict = {}
for component_info in components: for component_info in components:
component_name = component_info['name'] component_name = component_info['name']
component = component_module.newContent() component = component_module.newContent(title=component_name)
component_dict[component_name] = component component_dict[component_name] = component
variation1 = component.newContent( variation1 = component.newContent(
portal_type=self.component_variation_portal_type, portal_type=self.component_variation_portal_type,
...@@ -137,6 +136,7 @@ class TestTransformation(TestOrderMixin,ERP5TypeTestCase): ...@@ -137,6 +136,7 @@ class TestTransformation(TestOrderMixin,ERP5TypeTestCase):
supply_cell = supply_line.newCell( supply_cell = supply_line.newCell(
'variation/apparel_component_module/%s/%d' % \ 'variation/apparel_component_module/%s/%d' % \
(component.getId(),(i+1)), (component.getId(),(i+1)),
portal_type='Supply Cell',
base_id='path') base_id='path')
supply_cell.edit( supply_cell.edit(
membership_criterion_base_category = ['variation'], membership_criterion_base_category = ['variation'],
...@@ -718,5 +718,3 @@ class TestTransformation(TestOrderMixin,ERP5TypeTestCase): ...@@ -718,5 +718,3 @@ class TestTransformation(TestOrderMixin,ERP5TypeTestCase):
sequence_list.addSequenceString(sequence_string) sequence_list.addSequenceString(sequence_string)
sequence_list.play(self) sequence_list.play(self)
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