[Erp5-report] r27659 - /erp5/trunk/products/ERP5/tests/testBPMCore.py

nobody at svn.erp5.org nobody at svn.erp5.org
Thu Jun 18 16:42:03 CEST 2009


Author: luke
Date: Thu Jun 18 16:42:01 2009
New Revision: 27659

URL: http://svn.erp5.org?rev=27659&view=rev
Log:
 - check that business path category is more important that one on context

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

Modified: erp5/trunk/products/ERP5/tests/testBPMCore.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/tests/testBPMCore.py?rev=27659&r1=27658&r2=27659&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/tests/testBPMCore.py [utf8] (original)
+++ erp5/trunk/products/ERP5/tests/testBPMCore.py [utf8] Thu Jun 18 16:42:01 2009
@@ -2410,6 +2410,21 @@
     self.assertEquals(source_node.getRelativeUrl(),
       business_path.getSource(context=context_movement, default='something'))
 
+  def test_BuinessPathDynamicCategoryAccessProviderBusinessPathPrecedence(self):
+    movement_node = self.portal.organisation_module.newContent(
+                    portal_type='Organisation')
+    path_node = self.portal.organisation_module.newContent(
+                    portal_type='Organisation')
+    business_path = self.createBusinessPath()
+    business_path.setSourceMethodId('BusinessPath_getDefaultSourceList')
+    business_path.setSourceValue(path_node)
+
+    context_movement = self.createMovement()
+    context_movement.setSourceValue(movement_node)
+    self.assertEquals(path_node, business_path.getSourceValue())
+    self.assertEquals([path_node],
+                      business_path.getSourceValueList(context=context_movement))
+
   def test_BuinessPathDynamicCategoryAccessProviderEmptyMovement(self):
     business_path = self.createBusinessPath()
     business_path.setSourceMethodId('BusinessPath_getDefaultSourceList')




More information about the Erp5-report mailing list