[Erp5-report] r40350 luke - /erp5/trunk/products/ERP5/tests/testERP5WebWithDms.py

nobody at svn.erp5.org nobody at svn.erp5.org
Thu Nov 18 11:20:28 CET 2010


Author: luke
Date: Thu Nov 18 11:20:28 2010
New Revision: 40350

URL: http://svn.erp5.org?rev=40350&view=rev
Log:
 - check document publication workflow transition on web pages

Modified:
    erp5/trunk/products/ERP5/tests/testERP5WebWithDms.py

Modified: erp5/trunk/products/ERP5/tests/testERP5WebWithDms.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/tests/testERP5WebWithDms.py?rev=40350&r1=40349&r2=40350&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/tests/testERP5WebWithDms.py [utf8] (original)
+++ erp5/trunk/products/ERP5/tests/testERP5WebWithDms.py [utf8] Thu Nov 18 11:20:28 2010
@@ -693,6 +693,31 @@ class TestERP5WebWithDms(ERP5TypeTestCas
     # Resizing works
     self.assertTrue(len(large_image) > len(small_image))
 
+  def _test_document_publication_workflow(self, portal_type, transition):
+    document = self.portal.web_page_module.newContent(portal_type=portal_type)
+    self.portal.portal_workflow.doActionFor(document, transition)
+
+  def test_document_publication_workflow_WebPage_publish(self):
+    self._test_document_publication_workflow('Web Page', 'publish_action')
+
+  def test_document_publication_workflow_WebPage_publish_alive(self):
+    self._test_document_publication_workflow('Web Page',
+        'publish_alive_action')
+
+  def test_document_publication_workflow_WebPage_release(self):
+    self._test_document_publication_workflow('Web Page', 'release_action')
+
+  def test_document_publication_workflow_WebPage_release_alive(self):
+    self._test_document_publication_workflow('Web Page',
+        'release_alive_action')
+
+  def test_document_publication_workflow_WebPage_share(self):
+    self._test_document_publication_workflow('Web Page', 'share_action')
+
+  def test_document_publication_workflow_WebPage_share_alive(self):
+    self._test_document_publication_workflow('Web Page',
+        'share_alive_action')
+
 def test_suite():
   suite = unittest.TestSuite()
   suite.addTest(unittest.makeSuite(TestERP5WebWithDms))




More information about the Erp5-report mailing list