Commit bd8a92fe authored by Łukasz Nowak's avatar Łukasz Nowak

- simplify deletion of previous data


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@43432 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 864f6b97
...@@ -108,13 +108,13 @@ class TestOOoImportMixin(ERP5TypeTestCase): ...@@ -108,13 +108,13 @@ class TestOOoImportMixin(ERP5TypeTestCase):
def beforeTearDown(self): def beforeTearDown(self):
transaction.abort() transaction.abort()
region = self.portal.portal_categories.region for parent in [
region.manage_delObjects(list(region.objectIds())) self.portal.portal_categories.region,
self.portal.portal_categories.gender,
self.portal.portal_categories.function,
]:
parent.deleteContent(list(parent.objectIds()))
self.portal.portal_preferences.manage_delObjects([self.pref.getId()]) self.portal.portal_preferences.manage_delObjects([self.pref.getId()])
gender = self.portal.portal_categories.gender
function = self.portal.portal_categories.function
gender.manage_delObjects(list(gender.objectIds()))
function.manage_delObjects(list(function.objectIds()))
transaction.commit() transaction.commit()
self.tic() self.tic()
......
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