Commit fb89d5eb authored by Yusei Tahara's avatar Yusei Tahara

Add test step for the bug #1082. The previous change was not enough.

Merge stepVerifyTaskReportDescription into stepVerifyGeneratedTaskReportLines.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@28916 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 78ee1eff
...@@ -68,8 +68,7 @@ class TestTaskMixin: ...@@ -68,8 +68,7 @@ class TestTaskMixin:
stepSetTaskPriceCurrency \ stepSetTaskPriceCurrency \
stepConfirmTask \ stepConfirmTask \
stepTic \ stepTic \
stepSetTaskReport \ stepSetTaskReport '
stepVerifyTaskReportDescription '
default_task_sequence_two_lines = '\ default_task_sequence_two_lines = '\
stepLogin \ stepLogin \
...@@ -86,8 +85,7 @@ class TestTaskMixin: ...@@ -86,8 +85,7 @@ class TestTaskMixin:
stepFillTaskLineWithData \ stepFillTaskLineWithData \
stepConfirmTask \ stepConfirmTask \
stepTic \ stepTic \
stepSetTaskReport \ stepSetTaskReport '
stepVerifyTaskReportDescription '
default_task_report_sequence = '\ default_task_report_sequence = '\
stepLogin \ stepLogin \
...@@ -294,6 +292,7 @@ class TestTaskMixin: ...@@ -294,6 +292,7 @@ class TestTaskMixin:
task_line_quantity = self.default_quantity, task_line_quantity = self.default_quantity,
task_line_price = self.default_price, task_line_price = self.default_price,
task_line_requirement_value = requirement, task_line_requirement_value = requirement,
task_line_description = 'Default Task Line Description',
) )
def stepCreateSimpleTaskReport(self,sequence=None, sequence_list=None, **kw): def stepCreateSimpleTaskReport(self,sequence=None, sequence_list=None, **kw):
...@@ -392,7 +391,8 @@ class TestTaskMixin: ...@@ -392,7 +391,8 @@ class TestTaskMixin:
task = sequence.get('task') task = sequence.get('task')
task_line = task.newContent( task_line = task.newContent(
portal_type=self.task_line_portal_type, portal_type=self.task_line_portal_type,
title='New Task Line') title='New Task Line',
description='New Task Line Description')
sequence.edit(task_line=task_line) sequence.edit(task_line=task_line)
def stepFillTaskLineWithData(self, sequence=None, sequence_list=None, **kw): def stepFillTaskLineWithData(self, sequence=None, sequence_list=None, **kw):
...@@ -434,16 +434,12 @@ class TestTaskMixin: ...@@ -434,16 +434,12 @@ class TestTaskMixin:
self.assertTrue(task_line.getQuantity() in task_report_quantity_list) self.assertTrue(task_line.getQuantity() in task_report_quantity_list)
self.assertTrue(task_line.getPrice() in task_report_price_list) self.assertTrue(task_line.getPrice() in task_report_price_list)
def stepVerifyTaskReportDescription(self, sequence=None, for task_report_line in task_report.contentValues(portal_type='Task Report Line'):
sequence_list=None, **kw): simulation_movement = task_report_line.getDeliveryRelatedValue()
""" task_line = simulation_movement.getOrderValue()
Verify that task description is copied to task report. self.assert_(task_line.getDescription())
""" self.assertEqual(task_line.getDescription(),
task_report = sequence.get('task_report') task_report_line.getDescription())
task = sequence.get('task')
self.assert_(task_report.getDescription())
self.assertEqual(task_report.getDescription(),
task.getDescription())
def stepVerifyTaskReportCausalityState(self, sequence=None, def stepVerifyTaskReportCausalityState(self, sequence=None,
sequence_list=None, **kw): sequence_list=None, **kw):
......
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