Commit 5ef71b8b authored by Jérome Perrin's avatar Jérome Perrin

use self.assertRaises


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@9012 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 5d636802
......@@ -145,12 +145,8 @@ class TestAmount(ERP5TypeTestCase):
Test the method GetVariationPropertyDict.
"""
amount = sequence.get('amount')
try:
amount.setVariationPropertyDict(self.variation_property_dict)
except KeyError:
return
else:
raise KeyError
self.assertRaises(KeyError, amount.setVariationPropertyDict,
self.variation_property_dict)
def stepSetVariationPropertyDict(self, sequence=None,
sequence_list=None, **kw):
......@@ -181,12 +177,8 @@ class TestAmount(ERP5TypeTestCase):
Test the method GetVariationPropertyDict.
"""
amount = sequence.get('amount')
try:
amount.setVariationPropertyDict(self.failed_variation_property_dict)
except KeyError:
return
else:
raise KeyError
self.assertRaises(KeyError, amount.setVariationPropertyDict,
self.failed_variation_property_dict)
def stepCheckEdit(self, sequence=None, 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