[Erp5-report] r26384 - /erp5/trunk/products/ERP5/tests/testERP5Base.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Thu Apr 9 21:51:09 CEST 2009
Author: kazuhiko
Date: Thu Apr 9 21:51:08 2009
New Revision: 26384
URL: http://svn.erp5.org?rev=26384&view=rev
Log:
use absolute_url(relative=1) instead of getRelativeUrl() in ERP5Site_checkDataWithScript's test, because 'portal_categories/' is eliminated in Category's getRelativeUrl() value.
Modified:
erp5/trunk/products/ERP5/tests/testERP5Base.py
Modified: erp5/trunk/products/ERP5/tests/testERP5Base.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/tests/testERP5Base.py?rev=26384&r1=26383&r2=26384&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/tests/testERP5Base.py [utf8] (original)
+++ erp5/trunk/products/ERP5/tests/testERP5Base.py [utf8] Thu Apr 9 21:51:08 2009
@@ -1315,7 +1315,7 @@
def test_ERP5Site_checkDataWithScript(self):
test = 'test_ERP5Site_checkDataWithScript'
createZODBPythonScript(self.getSkinsTool().custom, test, '',
- 'return context.getRelativeUrl(),')
+ 'return context.absolute_url(relative=1),')
organisation = self.getOrganisationModule() \
.newContent(portal_type='Organisation')
@@ -1335,7 +1335,7 @@
self.assertEquals(len(relative_url_list), len(set(relative_url_list)))
for obj in organisation, person, person.getDefaultEmailValue():
- self.assertTrue(obj.getRelativeUrl() in relative_url_list)
+ self.assertTrue(obj.absolute_url(relative=1) in relative_url_list)
for relative_url in relative_url_list:
self.assertTrue('/' in relative_url)
self.assertNotEquals(None, self.portal.unrestrictedTraverse(relative_url))
More information about the Erp5-report
mailing list