Commit e3d1aac2 authored by Jérome Perrin's avatar Jérome Perrin

use variables to choose if we want to run test quietly or not.



git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@10822 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent f584b5a3
...@@ -36,25 +36,30 @@ try: ...@@ -36,25 +36,30 @@ try:
except ImportError: except ImportError:
pass pass
# Quiet messages when installing products
install_product_quiet = 0
# Quiet messages when installing business templates
install_bt5_quiet = 0
# Std Zope Products # Std Zope Products
ZopeTestCase.installProduct('ExtFile') ZopeTestCase.installProduct('ExtFile', quiet=install_product_quiet)
ZopeTestCase.installProduct('Photo') ZopeTestCase.installProduct('Photo', quiet=install_product_quiet)
ZopeTestCase.installProduct('Formulator') ZopeTestCase.installProduct('Formulator', quiet=install_product_quiet)
ZopeTestCase.installProduct('FCKeditor') ZopeTestCase.installProduct('FCKeditor', quiet=install_product_quiet)
ZopeTestCase.installProduct('ZSQLMethods') ZopeTestCase.installProduct('ZSQLMethods', quiet=install_product_quiet)
ZopeTestCase.installProduct('ZMySQLDA') ZopeTestCase.installProduct('ZMySQLDA', quiet=install_product_quiet)
ZopeTestCase.installProduct('ZSQLCatalog') ZopeTestCase.installProduct('ZSQLCatalog', quiet=install_product_quiet)
ZopeTestCase.installProduct('ZMailIn') ZopeTestCase.installProduct('ZMailIn', quiet=install_product_quiet)
ZopeTestCase.installProduct('ZGDChart') ZopeTestCase.installProduct('ZGDChart', quiet=install_product_quiet)
ZopeTestCase.installProduct('ZCTextIndex') ZopeTestCase.installProduct('ZCTextIndex', quiet=install_product_quiet)
ZopeTestCase.installProduct('MailHost') ZopeTestCase.installProduct('MailHost', quiet=install_product_quiet)
ZopeTestCase.installProduct('PageTemplates') ZopeTestCase.installProduct('PageTemplates', quiet=install_product_quiet)
ZopeTestCase.installProduct('PythonScripts') ZopeTestCase.installProduct('PythonScripts', quiet=install_product_quiet)
ZopeTestCase.installProduct('ExternalMethod') ZopeTestCase.installProduct('ExternalMethod', quiet=install_product_quiet)
try: try:
# Workaround iHotFix patch that doesn't work with # Workaround iHotFix patch that doesn't work with
# ZopeTestCase REQUESTs # ZopeTestCase REQUESTs
ZopeTestCase.installProduct('iHotfix') ZopeTestCase.installProduct('iHotfix', quiet=install_product_quiet)
from Products import iHotfix from Products import iHotfix
from StringIO import StringIO as OrigStringIO from StringIO import StringIO as OrigStringIO
from types import UnicodeType from types import UnicodeType
...@@ -71,41 +76,41 @@ try: ...@@ -71,41 +76,41 @@ try:
iHotfix.iHotfixStringIO = UnicodeSafeStringIO iHotfix.iHotfixStringIO = UnicodeSafeStringIO
except ImportError: except ImportError:
pass pass
ZopeTestCase.installProduct('Localizer') ZopeTestCase.installProduct('Localizer', quiet=install_product_quiet)
ZopeTestCase.installProduct('TimerService') ZopeTestCase.installProduct('TimerService', quiet=install_product_quiet)
# CMF # CMF
ZopeTestCase.installProduct('CMFCore') ZopeTestCase.installProduct('CMFCore', quiet=install_product_quiet)
ZopeTestCase.installProduct('CMFDefault') ZopeTestCase.installProduct('CMFDefault', quiet=install_product_quiet)
ZopeTestCase.installProduct('CMFTopic') ZopeTestCase.installProduct('CMFTopic', quiet=install_product_quiet)
ZopeTestCase.installProduct('DCWorkflow') ZopeTestCase.installProduct('DCWorkflow', quiet=install_product_quiet)
ZopeTestCase.installProduct('CMFCalendar') ZopeTestCase.installProduct('CMFCalendar', quiet=install_product_quiet)
# Based on CMF # Based on CMF
ZopeTestCase.installProduct('CMFPhoto') ZopeTestCase.installProduct('CMFPhoto', quiet=install_product_quiet)
ZopeTestCase.installProduct('BTreeFolder2') ZopeTestCase.installProduct('BTreeFolder2', quiet=install_product_quiet)
ZopeTestCase.installProduct('CMFReportTool') # Not required by ERP5Type but required by ERP5Form ZopeTestCase.installProduct('CMFReportTool', quiet=install_product_quiet) # Not required by ERP5Type but required by ERP5Form
ZopeTestCase.installProduct('CMFMailIn') ZopeTestCase.installProduct('CMFMailIn', quiet=install_product_quiet)
ZopeTestCase.installProduct('TranslationService') ZopeTestCase.installProduct('TranslationService', quiet=install_product_quiet)
# Security Stuff # Security Stuff
ZopeTestCase.installProduct('NuxUserGroups') ZopeTestCase.installProduct('NuxUserGroups', quiet=install_product_quiet)
ZopeTestCase.installProduct('PluggableAuthService') ZopeTestCase.installProduct('PluggableAuthService', quiet=install_product_quiet)
ZopeTestCase.installProduct('ERP5Security') ZopeTestCase.installProduct('ERP5Security', quiet=install_product_quiet)
# Debugging # Debugging
ZopeTestCase.installProduct('VerboseSecurity') ZopeTestCase.installProduct('VerboseSecurity', quiet=install_product_quiet)
ZopeTestCase.installProduct('Zelenium') ZopeTestCase.installProduct('Zelenium', quiet=install_product_quiet)
# ERP5 # ERP5
ZopeTestCase.installProduct('CMFActivity') ZopeTestCase.installProduct('CMFActivity', quiet=install_product_quiet)
ZopeTestCase.installProduct('ERP5Catalog') ZopeTestCase.installProduct('ERP5Catalog', quiet=install_product_quiet)
ZopeTestCase.installProduct('ERP5Type') ZopeTestCase.installProduct('ERP5Type', quiet=install_product_quiet)
ZopeTestCase.installProduct('ERP5Form') ZopeTestCase.installProduct('ERP5Form', quiet=install_product_quiet)
ZopeTestCase.installProduct('ERP5SyncML') ZopeTestCase.installProduct('ERP5SyncML', quiet=install_product_quiet)
ZopeTestCase.installProduct('CMFCategory') ZopeTestCase.installProduct('CMFCategory', quiet=install_product_quiet)
ZopeTestCase.installProduct('ERP5') ZopeTestCase.installProduct('ERP5', quiet=install_product_quiet)
ZopeTestCase.installProduct('ZMySQLDDA') ZopeTestCase.installProduct('ZMySQLDDA', quiet=install_product_quiet)
# Install everything else which looks like related to ERP5 # Install everything else which looks like related to ERP5
from OFS.Application import get_products from OFS.Application import get_products
...@@ -119,7 +124,7 @@ for priority, product_name, index, product_dir in get_products(): ...@@ -119,7 +124,7 @@ for priority, product_name, index, product_dir in get_products():
or os.path.isdir(os.path.join(product_dir, product_name, 'PropertySheet')) \ or os.path.isdir(os.path.join(product_dir, product_name, 'PropertySheet')) \
or os.path.isdir(os.path.join(product_dir, product_name, 'Constraint')) \ or os.path.isdir(os.path.join(product_dir, product_name, 'Constraint')) \
or os.path.isdir(os.path.join(product_dir, product_name, 'Tool')): or os.path.isdir(os.path.join(product_dir, product_name, 'Tool')):
ZopeTestCase.installProduct(product_name) ZopeTestCase.installProduct(product_name, quiet=install_product_quiet)
# Install Document types (circumvent different init order in ZopeTestCase) # Install Document types (circumvent different init order in ZopeTestCase)
from Products.ERP5Type.InitGenerator import initializeProductDocumentRegistry from Products.ERP5Type.InitGenerator import initializeProductDocumentRegistry
...@@ -297,6 +302,7 @@ class ERP5TypeTestCase(PortalTestCase): ...@@ -297,6 +302,7 @@ class ERP5TypeTestCase(PortalTestCase):
portal_name=self.getPortalName(), portal_name=self.getPortalName(),
title=self.getTitle(), title=self.getTitle(),
create_activities=create_activities, create_activities=create_activities,
quiet=install_bt5_quiet,
hot_reindexing=hot_reindexing) hot_reindexing=hot_reindexing)
PortalTestCase.setUp(self) PortalTestCase.setUp(self)
self._updateConnectionStrings() self._updateConnectionStrings()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment