Commit 7f8e6923 authored by Jérome Perrin's avatar Jérome Perrin

Using documentation helper should not generate any activities.



git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@15779 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 139a3740
...@@ -3046,6 +3046,7 @@ class DocumentationHelper(Base): ...@@ -3046,6 +3046,7 @@ class DocumentationHelper(Base):
return 1 return 1
return 0 return 0
class TempDocumentationHelper(DocumentationHelper, TempBase): class TempDocumentationHelper(DocumentationHelper, TempBase):
"""Temporary version of Documentation Helper. """Temporary version of Documentation Helper.
...@@ -3054,5 +3055,8 @@ class TempDocumentationHelper(DocumentationHelper, TempBase): ...@@ -3054,5 +3055,8 @@ class TempDocumentationHelper(DocumentationHelper, TempBase):
required that all temp objects have a corresponding "real" class as required that all temp objects have a corresponding "real" class as
klass.__bases__[0] klass.__bases__[0]
""" """
# inheritence fixes
reindexObject = TempBase.reindexObject
recursiveReindexObject = TempBase.recursiveReindexObject
...@@ -117,6 +117,17 @@ class TestClassTool(ERP5TypeTestCase): ...@@ -117,6 +117,17 @@ class TestClassTool(ERP5TypeTestCase):
self.assertNotEquals([], class_doc_helper.getStaticPropertyList()) self.assertNotEquals([], class_doc_helper.getStaticPropertyList())
def test_DocumentationHelperActivities(self):
# Using documentation helpers should not create any activity
portal = self.getPortal()
folder = portal.newContent(portal_type='Folder', id='test_folder')
get_transaction().commit()
self.tic()
doc_helper = folder.asDocumentationHelper()
get_transaction().commit()
self.assertEquals(0, len(portal.portal_activities.getMessageList()))
import unittest import unittest
def test_suite(): def test_suite():
suite = unittest.TestSuite() suite = unittest.TestSuite()
......
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