[Erp5-report] r26982 - /erp5/trunk/products/ERP5Security/tests/testERP5Security.py

nobody at svn.erp5.org nobody at svn.erp5.org
Thu May 14 14:03:02 CEST 2009


Author: jerome
Date: Thu May 14 14:03:02 2009
New Revision: 26982

URL: http://svn.erp5.org?rev=26982&view=rev
Log:
get_transaction -> transaction

Modified:
    erp5/trunk/products/ERP5Security/tests/testERP5Security.py

Modified: erp5/trunk/products/ERP5Security/tests/testERP5Security.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Security/tests/testERP5Security.py?rev=26982&r1=26981&r2=26982&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Security/tests/testERP5Security.py [utf8] (original)
+++ erp5/trunk/products/ERP5Security/tests/testERP5Security.py [utf8] Thu May 14 14:03:02 2009
@@ -63,7 +63,7 @@
     clearCache(cache_factory_list=('erp5_content_short', ))
     self.getPersonModule().manage_delObjects([x for x in
                              self.getPersonModule().objectIds()])
-    get_transaction().commit()
+    transaction.commit()
     self.tic()
   
   def login(self):
@@ -114,7 +114,7 @@
                                        stop_date=assignment_stop_date,)
     if open_assignment:
       assignment.open()
-    get_transaction().commit()
+    transaction.commit()
     self.tic()
     return new_person
 
@@ -350,7 +350,7 @@
                                   site='subcat',
                                   function='subcat' )
     assignment.open()
-    get_transaction().commit()
+    transaction.commit()
     self.tic()
   
   def beforeTearDown(self):
@@ -366,7 +366,7 @@
     for module in self.portal.objectValues(spec=('ERP5 Folder',)):
       module.manage_delObjects([x for x in module.objectIds()])
     # commit this
-    get_transaction().commit()
+    transaction.commit()
     self.tic()
     # XXX Isn't it better to clear the cache when deleting a Person ?
     clearCache(cache_factory_list=('erp5_content_short', ))
@@ -475,21 +475,21 @@
 
     # getUserByLogin accept login as a string
     self.portal.portal_caches.clearAllCache()
-    get_transaction().commit()
+    transaction.commit()
     person_list = self.portal.acl_users.erp5_users.getUserByLogin(self.username)
     self.assertEquals(1, len(person_list))
     self.assertEquals(self.username, person_list[0].getReference())
 
     # getUserByLogin accept login as a list
     self.portal.portal_caches.clearAllCache()
-    get_transaction().commit()
+    transaction.commit()
     person_list = self.portal.acl_users.erp5_users.getUserByLogin([self.username])
     self.assertEquals(1, len(person_list))
     self.assertEquals(self.username, person_list[0].getReference())
 
     # getUserByLogin accept login as a tuple
     self.portal.portal_caches.clearAllCache()
-    get_transaction().commit()
+    transaction.commit()
     person_list = self.portal.acl_users.erp5_users.getUserByLogin((self.username,))
     self.assertEquals(1, len(person_list))
     self.assertEquals(self.username, person_list[0].getReference())
@@ -497,7 +497,7 @@
     # PreferenceTool pass a user as parameter
     user = getSecurityManager().getUser()
     self.portal.portal_caches.clearAllCache()
-    get_transaction().commit()
+    transaction.commit()
     person_list = self.portal.acl_users.erp5_users.getUserByLogin(user)
     self.assertEquals(1, len(person_list))
     self.assertEquals(self.username, person_list[0].getReference())
@@ -517,7 +517,7 @@
     assignment = loginable_person.newContent(portal_type='Assignment',
                                              function='another_subcat')
     assignment.open()
-    get_transaction().commit()
+    transaction.commit()
     self.tic()
 
     person_module_type_information = self.getTypesTool()['Person Module']
@@ -530,7 +530,7 @@
       base_category_script='',
       base_category='')
     person_module_type_information.updateRoleMapping()
-    get_transaction().commit()
+    transaction.commit()
     self.tic()
 
     person_module_path = self.getPersonModule().absolute_url(relative=1)
@@ -547,7 +547,7 @@
     self.getOrganisationModule().newContent(portal_type='Organisation',
                                             id='my_company',
                                             title='Nexedi')
-    get_transaction().commit()
+    transaction.commit()
     self.tic()
     response = self.publish('/%s/my_company/getTitle' % self.getOrganisationModule().absolute_url(relative=1),
                             basic='guest:guest')




More information about the Erp5-report mailing list