Commit 6b3a7a96 authored by Nicolas Dumazet's avatar Nicolas Dumazet

fail with AssertionError instead of UnboundLocalError if not cell_list


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@35084 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 7800d06d
...@@ -1045,7 +1045,7 @@ class TestOrderMixin: ...@@ -1045,7 +1045,7 @@ class TestOrderMixin:
""" """
order_line = sequence.get('order_line') order_line = sequence.get('order_line')
cell_list = order_line.objectValues(portal_type=self.order_cell_portal_type) cell_list = order_line.objectValues(portal_type=self.order_cell_portal_type)
if len(cell_list) > 0: self.assertTrue(len(cell_list) > 0)
order_cell = cell_list[0].getObject() order_cell = cell_list[0].getObject()
order_cell.setStartDate(self.datetime + 99) order_cell.setStartDate(self.datetime + 99)
......
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