[Erp5-report] r17880 - /erp5/trunk/products/ERP5/tests/testCRM.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Wed Nov 28 17:16:32 CET 2007
Author: jerome
Date: Wed Nov 28 17:16:28 2007
New Revision: 17880
URL: http://svn.erp5.org?rev=17880&view=rev
Log:
When an email is ingested, we try to find the related campaign, for now, just
try that we don't blindly get the first campaign.
Modified:
erp5/trunk/products/ERP5/tests/testCRM.py
Modified: erp5/trunk/products/ERP5/tests/testCRM.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/tests/testCRM.py?rev=17880&r1=17879&r2=17880&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/tests/testCRM.py (original)
+++ erp5/trunk/products/ERP5/tests/testCRM.py Wed Nov 28 17:16:28 2007
@@ -52,6 +52,7 @@
# set prefered file name regular expression
pref = portal.portal_preferences.default_site_preference
pref.setPreferredDocumentFileNameRegularExpression('.*')
+ pref.setPreferredDocumentReferenceRegularExpression('.*')
pref.enable()
# XXX do this in ERP5Site.py ?
@@ -139,6 +140,20 @@
get_transaction().commit()
self.tic()
self.assertEquals('person_module/me', event.getDestination())
+
+ def test_follow_up(self):
+ # follow up is found automatically, based on the content of the mail, and
+ # what you defined in preference regexpr.
+ # But, we don't want it to associate with the first campaign simply
+ # because we searched against nothing
+ self.portal.campaign_module.newContent(portal_type='Campaign')
+ get_transaction().commit()
+ self.tic()
+ event = self._ingestMail('simple')
+ get_transaction().commit()
+ self.tic()
+ self.assertEquals(None, event.getFollowUp())
+
## TODO:
## def test_forwarder_mail(self):
More information about the Erp5-report
mailing list