[Erp5-report] r29235 - /erp5/trunk/products/ERP5/tests/testTemplate.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Mon Sep 28 17:33:32 CEST 2009
Author: jerome
Date: Mon Sep 28 17:33:32 2009
New Revision: 29235
URL: http://svn.erp5.org?rev=29235&view=rev
Log:
also assert that non indexable templates cannot be found during catalog searches.
Modified:
erp5/trunk/products/ERP5/tests/testTemplate.py
Modified: erp5/trunk/products/ERP5/tests/testTemplate.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/tests/testTemplate.py?rev=29235&r1=29234&r2=29235&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/tests/testTemplate.py [utf8] (original)
+++ erp5/trunk/products/ERP5/tests/testTemplate.py [utf8] Mon Sep 28 17:33:32 2009
@@ -309,8 +309,16 @@
self.tic()
self.assertTrue(document.isIndexable)
self.assertEqual(len(preference.objectIds()), 1)
- for template in preference.objectValues():
- self.assertFalse(template.isIndexable)
+ template = preference.objectValues()[0]
+ self.assertFalse(template.isIndexable)
+
+ # Because they are not indexable, they cannot be found by catalog
+ transaction.commit()
+ self.tic()
+ self.assertEquals(0, len(self.portal.portal_catalog(uid=template.getUid())))
+ template_line = template.objectValues()[0]
+ self.assertEquals(0,
+ len(self.portal.portal_catalog(uid=template_line.getUid())))
# and this is still true if you create two templates from the same document
# #929
More information about the Erp5-report
mailing list