[Checkins] SVN: z3c.recipe.i18n/trunk/ - Fixed bug where zcml_strings collect the same path more then once because it follows the configuration zcml for each package.

Roger Ineichen roger at projekt01.ch
Mon Jun 8 05:07:23 EDT 2009


Log message for revision 100741:
  - Fixed bug where zcml_strings collect the same path more then once because it follows the configuration zcml for each package.
  - Fixed tests, added NORMALIZE_WHITESPACE

Changed:
  U   z3c.recipe.i18n/trunk/CHANGES.txt
  U   z3c.recipe.i18n/trunk/buildout.cfg
  U   z3c.recipe.i18n/trunk/setup.py
  U   z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/README.txt
  U   z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/i18nextract.py
  U   z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/tests.py

-=-
Modified: z3c.recipe.i18n/trunk/CHANGES.txt
===================================================================
--- z3c.recipe.i18n/trunk/CHANGES.txt	2009-06-08 08:47:46 UTC (rev 100740)
+++ z3c.recipe.i18n/trunk/CHANGES.txt	2009-06-08 09:07:22 UTC (rev 100741)
@@ -5,6 +5,9 @@
 0.5.4 (unreleases)
 ------------------
 
+- Fix bug where zcml_strings collect the same path more then once because it
+  follows the configuration zcml for each package.
+
 - Fix bug where i18ncompile miscalculated domains containing ".", everything
   after the "." was ignored.
 

Modified: z3c.recipe.i18n/trunk/buildout.cfg
===================================================================
--- z3c.recipe.i18n/trunk/buildout.cfg	2009-06-08 08:47:46 UTC (rev 100740)
+++ z3c.recipe.i18n/trunk/buildout.cfg	2009-06-08 09:07:22 UTC (rev 100741)
@@ -1,7 +1,11 @@
 [buildout]
-parts = test
+parts = test checker
 develop = .
 
 [test]
 recipe = zc.recipe.testrunner
 eggs = z3c.recipe.i18n [test]
+
+[checker]
+recipe = lovely.recipe:importchecker
+path = src/z3c/recipe/i18n

Modified: z3c.recipe.i18n/trunk/setup.py
===================================================================
--- z3c.recipe.i18n/trunk/setup.py	2009-06-08 08:47:46 UTC (rev 100740)
+++ z3c.recipe.i18n/trunk/setup.py	2009-06-08 09:07:22 UTC (rev 100741)
@@ -62,18 +62,31 @@
     extras_require = dict(
         test = [
             'zope.testing',
-            'zope.app.locales',
             'zc.lockfile',
+                      'zope.app.component',
+                      'zope.app.publication',
+                      'zope.component',
+                      'zope.configuration',
+                      'zope.container',
+                      'zope.error',
+                      'zope.event',
+                      'zope.interface',
+                      'zope.location',
+                      'zope.processlifetime',
+                      'zope.session',
+                      'zope.site',
+                      'zope.security',
+                      'zope.traversing',
+                      'ZODB3',
             ],
         ),
     install_requires = [
-        'ZConfig >=2.4a5',
         'setuptools',
         'zc.buildout',
         'zc.recipe.egg',
-        'zope.testing',
+        'zope.app.appsetup',
+        'zope.app.locales',
         'zope.configuration',
-        'zc.lockfile',
         ],
     entry_points = {
         'zc.buildout': [

Modified: z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/README.txt
===================================================================
--- z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/README.txt	2009-06-08 08:47:46 UTC (rev 100740)
+++ z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/README.txt	2009-06-08 09:07:22 UTC (rev 100741)
@@ -24,45 +24,45 @@
 Options
 *******
 
-The 'app' recipe accepts the following options:
+The i18n recipe accepts the following options:
 
 eggs
-The names of one or more eggs, with their dependencies that should
-be included in the Python path of the generated scripts.
+  The names of one or more eggs, with their dependencies that should
+  be included in the Python path of the generated scripts.
 
 packages
-The names of one or more eggs which the messages should get extracted from.
-Note, this is different to the original zope.app.locales implementation.
-The original implementation uses one path as -d argument which assumes a 
-specific zope.* package structure with a lod style trunk setup.
+  The names of one or more eggs which the messages should get extracted from.
+  Note, this is different to the original zope.app.locales implementation.
+  The original implementation uses one path as -d argument which assumes a 
+  specific zope.* package structure with an old style trunk setup.
 
 domain
-The translation domain.
+  The translation domain.
 
 output
-The path of the output file relative to the package root.
+  The path of the output file relative to the package root.
 
 maker
-One or more module name which can get used as additional maker. This module
-must be located in the python path because it get resolved by
-zope.configuration.name.resolve. For a sample maker see 
-z3c.csvvocabulary.csvStrings.
+  One or more module name which can get used as additional maker. This module
+  must be located in the python path because it get resolved by
+  zope.configuration.name.resolve. For a sample maker see 
+  z3c.csvvocabulary.csvStrings.
 
 zcml (required)
-The contents of configuration used for extraction. Normaly used for load 
-meta configuration.
+  The contents of configuration used for extraction. Normaly used for load 
+  meta configuration.
 
 excludeDefaultDomain (optional, default=False)
-Exclude all messages found as part of the default domain. Messages are in
-this domain, if their domain could not be determined. This usually happens
-in page template snippets. (False if not used)
+  Exclude all messages found as part of the default domain. Messages are in
+  this domain, if their domain could not be determined. This usually happens
+  in page template snippets. (False if not used)
 
 pythonOnly (optional, default=False)
-Only extract message ids from Python (False if not used)
+  Only extract message ids from Python (False if not used)
 
 exludeDirectoryName (optional, default=[])
-Allows to specify one or more directory name, relative to the package, to 
-exclude. (None if not used)
+  Allows to specify one or more directory name, relative to the package, to 
+  exclude. (None if not used)
 
 environment
   A section name defining a set of environment variables that should be 
@@ -75,114 +75,119 @@
 
 Lets define some (bogus) eggs that we can use in our application:
 
->>> mkdir('outputDir')
->>> mkdir('demo1')
->>> write('demo1', 'setup.py',
-... '''
-... from setuptools import setup
-... setup(name = 'demo1')
-... ''')
+  >>> mkdir('outputDir')
+  >>> mkdir('demo1')
+  >>> write('demo1', 'setup.py',
+  ... '''
+  ... from setuptools import setup
+  ... setup(name = 'demo1')
+  ... ''')
+  
+  >>> mkdir('demo2')
+  >>> write('demo2', 'setup.py',
+  ... '''
+  ... from setuptools import setup
+  ... setup(name = 'demo2', install_requires='demo1')
+  ... ''')
 
->>> mkdir('demo2')
->>> write('demo2', 'setup.py',
-... '''
-... from setuptools import setup
-... setup(name = 'demo2', install_requires='demo1')
-... ''')
+Now check if the setup was correct:
 
+  >>> ls('bin')
+  -  buildout
+
 Lets create a minimal `buildout.cfg` file:
 
->>> write('buildout.cfg',
-... '''
-... [buildout]
-... parts = i18n
-... offline = true
-...
-... [i18n]
-... recipe = z3c.recipe.i18n:i18n
-... eggs = z3c.recipe.i18n
-... packages = demo1
-... domain = recipe
-... output = outputDir
-... zcml = <include package="z3c.recipe.tests" file="extract.zcml" />"
-... ''' % globals())
+  >>> write('buildout.cfg',
+  ... '''
+  ... [buildout]
+  ... parts = i18n
+  ... offline = true
+  ...
+  ... [i18n]
+  ... recipe = z3c.recipe.i18n:i18n
+  ... eggs = z3c.recipe.i18n
+  ... packages = demo1
+  ... domain = recipe
+  ... output = outputDir
+  ... zcml = <include package="z3c.recipe.tests" file="extract.zcml" />"
+  ... ''' % globals())
 
 Now, Let's run the buildout and see what we get:
 
->>> print system(join('bin', 'buildout')),
-Installing i18n.
-i18n: setting up i18n tools
-Generated script '/sample-buildout/bin/i18nextract'.
-Generated script '/sample-buildout/bin/i18nmergeall'.
-Generated script '/sample-buildout/bin/i18nstats'.
-Generated script '/sample-buildout/bin/i18ncompile'.
+  >>> print system(join('bin', 'buildout')),
+  Installing i18n.
+  i18n: setting up i18n tools
+  Generated script '/sample-buildout/bin/i18nextract'.
+  Generated script '/sample-buildout/bin/i18nmergeall'.
+  Generated script '/sample-buildout/bin/i18nstats'.
+  Generated script '/sample-buildout/bin/i18ncompile'.
 
 After running buildout, the bin folder contains the different i18n script:
 
->>> ls('bin')
--  buildout
--  i18ncompile
--  i18nextract
--  i18nmergeall
--  i18nstats
+  >>> ls('bin')
+  -  buildout
+  -  i18ncompile
+  -  i18nextract
+  -  i18nmergeall
+  -  i18nstats
 
 i18nextract
 -----------
 
 The i18nextract.py contains the following code:
 
->>> cat('bin', 'i18nextract')
-<BLANKLINE>
-import sys
-sys.path[0:0] = [
-...
-  ]
-<BLANKLINE>
-import os
-sys.argv[0] = os.path.abspath(sys.argv[0])
-os.chdir('...src')
-<BLANKLINE>
-<BLANKLINE>
-import z3c.recipe.i18n.i18nextract
-<BLANKLINE>
-if __name__ == '__main__':
-    z3c.recipe.i18n.i18nextract.main(['i18nextract', '-d', 'recipe', '-s', '/sample-buildout/parts/i18n/configure.zcml', '-o', '/sample-buildout/outputDir', '-p', 'demo1'])
+  >>> cat('bin', 'i18nextract')
+  <BLANKLINE>
+  import sys
+  sys.path[0:0] = [
+  ...
+    ]
+  <BLANKLINE>
+  import os
+  sys.argv[0] = os.path.abspath(sys.argv[0])
+  os.chdir('...src')
+  <BLANKLINE>
+  <BLANKLINE>
+  import z3c.recipe.i18n.i18nextract
+  <BLANKLINE>
+  if __name__ == '__main__':
+      z3c.recipe.i18n.i18nextract.main(['i18nextract', '-d', 'recipe', '-s', '/sample-buildout/parts/i18n/configure.zcml', '-o', '/sample-buildout/outputDir', '-p', 'demo1'])
 
 i18nmergeall
 ------------
 
 The i18nmergeall.py contains the following code:
 
->>> cat('bin', 'i18nmergeall')
-#!C:\Python24\python.exe
-<BLANKLINE>
-import sys
-sys.path[0:0] = [
-  ...
-  ]
-<BLANKLINE>
-import z3c.recipe.i18n.i18nmergeall
-<BLANKLINE>
-if __name__ == '__main__':
-    z3c.recipe.i18n.i18nmergeall.main(['i18nmergeall', '-l', '...outputDir'])
+  >>> cat('bin', 'i18nmergeall')
+  #!C:\Python24\python.exe
+  <BLANKLINE>
+  import sys
+  sys.path[0:0] = [
+    ...
+    ]
+  <BLANKLINE>
+  import z3c.recipe.i18n.i18nmergeall
+  <BLANKLINE>
+  if __name__ == '__main__':
+      z3c.recipe.i18n.i18nmergeall.main(['i18nmergeall', '-l', '...outputDir'])
 
 i18nstats
 ---------
 
 The i18nstats.py contains the following code:
 
->>> cat('bin', 'i18nstats')
-#!C:\Python24\python.exe
-<BLANKLINE>
-import sys
-sys.path[0:0] = [
-  ...
-  ]
-<BLANKLINE>
-import z3c.recipe.i18n.i18nstats
-<BLANKLINE>
-if __name__ == '__main__':
-    z3c.recipe.i18n.i18nstats.main(['i18nstats', '-l', '...outputDir'])
+  >>> cat('bin', 'i18nstats')
+  #!C:\Python24\python.exe
+  <BLANKLINE>
+  import sys
+  sys.path[0:0] = [
+    ...
+    ]
+  <BLANKLINE>
+  import z3c.recipe.i18n.i18nstats
+  <BLANKLINE>
+  if __name__ == '__main__':
+      z3c.recipe.i18n.i18nstats.main(['i18nstats', '-l', '...outputDir'])
 
 
 i18ncompile
@@ -190,18 +195,18 @@
 
 The i18ncompile.py contains the following code:
 
->>> cat('bin', 'i18ncompile')
-#!C:\Python24\python.exe
-<BLANKLINE>
-import sys
-sys.path[0:0] = [
-  ...
-  ]
-<BLANKLINE>
-import z3c.recipe.i18n.i18ncompile
-<BLANKLINE>
-if __name__ == '__main__':
-    z3c.recipe.i18n.i18ncompile.main(['i18ncompile', '-l', '...outputDir'])
+  >>> cat('bin', 'i18ncompile')
+  #!C:\Python24\python.exe
+  <BLANKLINE>
+  import sys
+  sys.path[0:0] = [
+    ...
+    ]
+  <BLANKLINE>
+  import z3c.recipe.i18n.i18ncompile
+  <BLANKLINE>
+  if __name__ == '__main__':
+      z3c.recipe.i18n.i18ncompile.main(['i18ncompile', '-l', '...outputDir'])
 
 
 Full Sample
@@ -209,105 +214,105 @@
 
 Lets create a `buildout.cfg` file using all available arguments:
 
->>> write('buildout.cfg',
-... '''
-... [buildout]
-... parts = i18n
-... offline = true
-...
-... [testenv]
-... fooDir = ${buildout:directory}/parts/foo
-...
-... [i18n]
-... recipe = z3c.recipe.i18n:i18n
-... eggs = z3c.recipe.i18n
-... packages = demo1
-... domain = recipe
-... output = outputDir
-... zcml = <include package="z3c.recipe.tests" file="extract.zcml" />"
-... maker = z3c.csvvocabulary.csvStrings
-... excludeDefaultDomain = true
-... pythonOnly = true
-... exludeDirectoryName = foo
-...                       bar
-... environment = testenv
-... ''' % globals())
+  >>> write('buildout.cfg',
+  ... '''
+  ... [buildout]
+  ... parts = i18n
+  ... offline = true
+  ...
+  ... [testenv]
+  ... fooDir = ${buildout:directory}/parts/foo
+  ...
+  ... [i18n]
+  ... recipe = z3c.recipe.i18n:i18n
+  ... eggs = z3c.recipe.i18n
+  ... packages = demo1
+  ... domain = recipe
+  ... output = outputDir
+  ... zcml = <include package="z3c.recipe.tests" file="extract.zcml" />"
+  ... maker = z3c.csvvocabulary.csvStrings
+  ... excludeDefaultDomain = true
+  ... pythonOnly = true
+  ... exludeDirectoryName = foo
+  ...                       bar
+  ... environment = testenv
+  ... ''' % globals())
 
 Now, Let's run the buildout and see what we get:
 
->>> print system(join('bin', 'buildout')),
-Uninstalling i18n.
-Installing i18n.
-i18n: setting up i18n tools
-Generated script '/sample-buildout/bin/i18nextract'.
-Generated script '/sample-buildout/bin/i18nmergeall'.
-Generated script '/sample-buildout/bin/i18nstats'.
-Generated script '/sample-buildout/bin/i18ncompile'.
+  >>> print system(join('bin', 'buildout')),
+  Uninstalling i18n.
+  Installing i18n.
+  i18n: setting up i18n tools
+  Generated script '/sample-buildout/bin/i18nextract'.
+  Generated script '/sample-buildout/bin/i18nmergeall'.
+  Generated script '/sample-buildout/bin/i18nstats'.
+  Generated script '/sample-buildout/bin/i18ncompile'.
 
 After running buildout, the bin folder contains the different i18n script:
 
->>> ls('bin')
--  buildout
--  i18ncompile
--  i18nextract
--  i18nmergeall
--  i18nstats
+  >>> ls('bin')
+  -  buildout
+  -  i18ncompile
+  -  i18nextract
+  -  i18nmergeall
+  -  i18nstats
 
 i18nextract
 -----------
 
 The i18nextract.py contains the following code:
 
->>> cat('bin', 'i18nextract')
-<BLANKLINE>
-import sys
-sys.path[0:0] = [
-...
-  ]
-<BLANKLINE>
-import os
-sys.argv[0] = os.path.abspath(sys.argv[0])
-os.chdir('...src')
-os.environ['fooDir'] = '/sample-buildout/parts/foo'
-<BLANKLINE>
-<BLANKLINE>
-import z3c.recipe.i18n.i18nextract
-<BLANKLINE>
-if __name__ == '__main__':
-    z3c.recipe.i18n.i18nextract.main(['i18nextract', '-d', 'recipe', '-s', '/sample-buildout/parts/i18n/configure.zcml', '-o', '/sample-buildout/outputDir', '--exclude-default-domain', '--python-only', '-m', 'z3c.csvvocabulary.csvStrings', '-p', 'demo1', '-x', 'foo', '-x', 'bar'])
+  >>> cat('bin', 'i18nextract')
+  <BLANKLINE>
+  import sys
+  sys.path[0:0] = [
+  ...
+    ]
+  <BLANKLINE>
+  import os
+  sys.argv[0] = os.path.abspath(sys.argv[0])
+  os.chdir('...src')
+  os.environ['fooDir'] = '/sample-buildout/parts/foo'
+  <BLANKLINE>
+  <BLANKLINE>
+  import z3c.recipe.i18n.i18nextract
+  <BLANKLINE>
+  if __name__ == '__main__':
+      z3c.recipe.i18n.i18nextract.main(['i18nextract', '-d', 'recipe', '-s', '/sample-buildout/parts/i18n/configure.zcml', '-o', '/sample-buildout/outputDir', '--exclude-default-domain', '--python-only', '-m', 'z3c.csvvocabulary.csvStrings', '-p', 'demo1', '-x', 'foo', '-x', 'bar'])
 
 i18nmergeall
 ------------
 
 The i18nmergeall.py contains the following code:
 
->>> cat('bin', 'i18nmergeall')
-#!C:\Python24\python.exe
-<BLANKLINE>
-import sys
-sys.path[0:0] = [
-...
-  ]
-<BLANKLINE>
-import z3c.recipe.i18n.i18nmergeall
-<BLANKLINE>
-if __name__ == '__main__':
-    z3c.recipe.i18n.i18nmergeall.main(['i18nmergeall', '-l', '...outputDir'])
+  >>> cat('bin', 'i18nmergeall')
+  #!C:\Python24\python.exe
+  <BLANKLINE>
+  import sys
+  sys.path[0:0] = [
+  ...
+    ]
+  <BLANKLINE>
+  import z3c.recipe.i18n.i18nmergeall
+  <BLANKLINE>
+  if __name__ == '__main__':
+      z3c.recipe.i18n.i18nmergeall.main(['i18nmergeall', '-l', '...outputDir'])
 
 i18nstats
 ---------
 
 The i18nstats.py contains the following code:
 
->>> cat('bin', 'i18nstats')
-#!C:\Python24\python.exe
-<BLANKLINE>
-import sys
-sys.path[0:0] = [
-...
-  ]
-<BLANKLINE>
-import z3c.recipe.i18n.i18nstats
-<BLANKLINE>
-if __name__ == '__main__':
-    z3c.recipe.i18n.i18nstats.main(['i18nstats', '-l', '...outputDir'])
+  >>> cat('bin', 'i18nstats')
+  #!C:\Python24\python.exe
+  <BLANKLINE>
+  import sys
+  sys.path[0:0] = [
+  ...
+    ]
+  <BLANKLINE>
+  import z3c.recipe.i18n.i18nstats
+  <BLANKLINE>
+  if __name__ == '__main__':
+      z3c.recipe.i18n.i18nstats.main(['i18nstats', '-l', '...outputDir'])

Modified: z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/i18nextract.py
===================================================================
--- z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/i18nextract.py	2009-06-08 08:47:46 UTC (rev 100740)
+++ z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/i18nextract.py	2009-06-08 09:07:22 UTC (rev 100741)
@@ -68,6 +68,35 @@
     sys.exit(code)
 
 
+def zcml_strings(path, domain="zope", site_zcml=None):
+    """Retrieve all ZCML messages from `dir` that are in the `domain`.
+    
+    Note, the pot maker runs in a loop for each package and the maker collects
+    only the given messages from such a package by the given path. This allows
+    us to collect messages from eggs and external packages. This also prevents
+    to collect the same message more then one time since we use the same zcml
+    configuration for each package path.
+    """
+    from zope.app.appsetup import config
+    context = config(site_zcml, features=("devmode",), execute=False)
+    catalog = context.i18n_strings.get(domain, {})
+    res = {}
+    duplicated = []
+    append = duplicated.append
+    for msg, locations  in catalog.items():
+        for filename, lineno in locations:
+            # only collect locations based on the given path
+            if filename.startswith(path):
+                id = '%s-%s-%s' % (msg, filename, lineno)
+                # skip duplicated entries
+                if id not in duplicated:
+                    append(id)
+                    l = res.get(msg, [])
+                    l.append((filename, lineno))
+                    res[msg] = l
+    return res
+
+
 def main(argv=sys.argv):
     try:
         opts, args = getopt.getopt(
@@ -128,7 +157,6 @@
     from zope.app.locales.extract import POTMaker
     from zope.app.locales.extract import py_strings
     from zope.app.locales.extract import tal_strings
-    from zope.app.locales.extract import zcml_strings
 
     # setup pot maker
     maker = POTMaker(output_file, '')
@@ -162,7 +190,8 @@
                                   exclude=exclude_dirs), basePath)
         for m in makers:
             poMaker = resolve(m)
-            maker.add(poMaker(path, basePath, exclude_dirs))
+            maker.add(poMaker(path, basePath, exclude_dirs), basePath)
+
     maker.write()
     print "output: %r\n" % output_file
 

Modified: z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/tests.py
===================================================================
--- z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/tests.py	2009-06-08 08:47:46 UTC (rev 100740)
+++ z3c.recipe.i18n/trunk/src/z3c/recipe/i18n/tests.py	2009-06-08 09:07:22 UTC (rev 100741)
@@ -12,29 +12,78 @@
 #
 ##############################################################################
 
-import os, re
-import pkg_resources
+import re
 
-import zc.buildout.testing
-
 import unittest
-import zope.testing
 from zope.testing import doctest, renormalizing
 
+import zc.buildout.testing
 
+
 def setUp(test):
     zc.buildout.testing.buildoutSetUp(test)
-    zc.buildout.testing.install_develop('z3c.recipe.i18n', test)
+    zc.buildout.testing.install('RestrictedPython', test)
     zc.buildout.testing.install('ZConfig', test)
+    zc.buildout.testing.install('ZODB3', test)
+    zc.buildout.testing.install('pytz', test)
+    zc.buildout.testing.install('transaction', test)
     zc.buildout.testing.install('zc.lockfile', test)
     zc.buildout.testing.install('zc.recipe.egg', test)
+    zc.buildout.testing.install('zdaemon', test)
+    zc.buildout.testing.install('zodbcode', test)
+    zc.buildout.testing.install('zope.annotation', test)
+    zc.buildout.testing.install('zope.app.appsetup', test)
+    zc.buildout.testing.install('zope.app.basicskin', test)
+    zc.buildout.testing.install('zope.app.component', test)
+    zc.buildout.testing.install('zope.app.container', test)
+    zc.buildout.testing.install('zope.app.form', test)
+    zc.buildout.testing.install('zope.app.interface', test)
     zc.buildout.testing.install('zope.app.locales', test)
+    zc.buildout.testing.install('zope.app.pagetemplate', test)
+    zc.buildout.testing.install('zope.app.publication', test)
+    zc.buildout.testing.install('zope.app.publisher', test)
+    zc.buildout.testing.install('zope.authentication', test)
+    zc.buildout.testing.install('zope.broken', test)
+    zc.buildout.testing.install('zope.browser', test)
+    zc.buildout.testing.install('zope.cachedescriptors', test)
+    zc.buildout.testing.install('zope.component', test)
+    zc.buildout.testing.install('zope.componentvocabulary', test)
     zc.buildout.testing.install('zope.configuration', test)
+    zc.buildout.testing.install('zope.container', test)
+    zc.buildout.testing.install('zope.contenttype', test)
+    zc.buildout.testing.install('zope.copy', test)
+    zc.buildout.testing.install('zope.copypastemove', test)
+    zc.buildout.testing.install('zope.datetime', test)
+    zc.buildout.testing.install('zope.deferredimport', test)
+    zc.buildout.testing.install('zope.deprecation', test)
+    zc.buildout.testing.install('zope.dottedname', test)
+    zc.buildout.testing.install('zope.dublincore', test)
+    zc.buildout.testing.install('zope.error', test)
     zc.buildout.testing.install('zope.event', test)
+    zc.buildout.testing.install('zope.exceptions', test)
+    zc.buildout.testing.install('zope.filerepresentation', test)
+    zc.buildout.testing.install('zope.formlib', test)
+    zc.buildout.testing.install('zope.hookable', test)
+    zc.buildout.testing.install('zope.i18n', test)
     zc.buildout.testing.install('zope.i18nmessageid', test)
     zc.buildout.testing.install('zope.interface', test)
+    zc.buildout.testing.install('zope.lifecycleevent', test)
+    zc.buildout.testing.install('zope.location', test)
+    zc.buildout.testing.install('zope.minmax', test)
+    zc.buildout.testing.install('zope.pagetemplate', test)
+    zc.buildout.testing.install('zope.processlifetime', test)
+    zc.buildout.testing.install('zope.proxy', test)
+    zc.buildout.testing.install('zope.publisher', test)
     zc.buildout.testing.install('zope.schema', test)
+    zc.buildout.testing.install('zope.security', test)
+    zc.buildout.testing.install('zope.session', test)
+    zc.buildout.testing.install('zope.site', test)
+    zc.buildout.testing.install('zope.size', test)
+    zc.buildout.testing.install('zope.tal', test)
+    zc.buildout.testing.install('zope.tales', test)
     zc.buildout.testing.install('zope.testing', test)
+    zc.buildout.testing.install('zope.traversing', test)
+    zc.buildout.testing.install_develop('z3c.recipe.i18n', test)
 
 
 checker = renormalizing.RENormalizing([
@@ -47,9 +96,11 @@
     (re.compile("""['"][^\n"']+z3c.recipe.i18n[^\n"']*['"],"""),
      "'/z3c.recipe.i18n',"),
     (re.compile('#![^\n]+\n'), ''),
-    (re.compile('-\S+-py\d[.]\d(-\S+)?.egg'),
-     '-pyN.N.egg',
-    ),
+    (re.compile('-\S+-py\d[.]\d(-\S+)?.egg'), '-pyN.N.egg',),    
+    # the following are for compatibility with Windows  
+    (re.compile('-  .*\.exe\n'), ''),  
+    (re.compile('-script.py'), ''),  
+
     ])
 
 
@@ -57,7 +108,8 @@
     return unittest.TestSuite(
         doctest.DocFileSuite('README.txt',
             setUp=setUp, tearDown=zc.buildout.testing.buildoutTearDown,
-            optionflags=doctest.ELLIPSIS, checker=checker),
+            optionflags=doctest.NORMALIZE_WHITESPACE|doctest.ELLIPSIS,
+            checker=checker),
         )
 
 



More information about the Checkins mailing list