[Zope3-checkins] SVN: Zope3/trunk/src/zope/configuration/ White and Typo fixes.

Stephan Richter srichter at cosmos.phy.tufts.edu
Sun Sep 3 14:46:39 EDT 2006


Log message for revision 69948:
  White and Typo fixes.
  

Changed:
  U   Zope3/trunk/src/zope/configuration/tests/test_xmlconfig.py
  U   Zope3/trunk/src/zope/configuration/xmlconfig.py

-=-
Modified: Zope3/trunk/src/zope/configuration/tests/test_xmlconfig.py
===================================================================
--- Zope3/trunk/src/zope/configuration/tests/test_xmlconfig.py	2006-09-03 18:45:51 UTC (rev 69947)
+++ Zope3/trunk/src/zope/configuration/tests/test_xmlconfig.py	2006-09-03 18:46:38 UTC (rev 69948)
@@ -34,7 +34,7 @@
     return self.column
 
 class FauxContext(object):
-  
+
   def setInfo(self, info):
     self.info = info
   def getInfo(self):
@@ -76,7 +76,7 @@
     File "tests//sample.zcml", line 1.1-7.16
     >>> context.end_called
     1
-    
+
     """
 
 def test_ConfigurationHandler_err_start():
@@ -85,7 +85,7 @@
     >>> class FauxContext(FauxContext):
     ...   def begin(self, *args):
     ...     raise AttributeError("xxx")
-    
+
     >>> context = FauxContext()
     >>> locator = FauxLocator('tests//sample.zcml', 1, 1)
     >>> handler = xmlconfig.ConfigurationHandler(context)
@@ -102,7 +102,7 @@
     >>> print v
     File "tests//sample.zcml", line 1.1
         AttributeError: xxx
-    
+
     """
 
 def test_ConfigurationHandler_err_end():
@@ -131,7 +131,7 @@
     >>> print v
     File "tests//sample.zcml", line 1.1-7.16
         AttributeError: xxx
-    
+
     """
 
 def clean_info_path(s):
@@ -159,12 +159,12 @@
     []
 
     >>> context.execute_actions()
-    
+
     >>> data = foo.data.pop()
 
     >>> data.args
     (('x', 'blah'), ('y', 0))
-    
+
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/configure.zcml", line 12.2-12.29
 
@@ -181,12 +181,12 @@
 
     >>> file_name = path("samplepackage", "configure.zcml")
     >>> context = xmlconfig.file(file_name)
-    
+
     >>> data = foo.data.pop()
 
     >>> data.args
     (('x', 'blah'), ('y', 0))
-    
+
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/configure.zcml", line 12.2-12.29
 
@@ -206,12 +206,12 @@
     >>> import zope.configuration.tests.samplepackage as package
     >>> xmlconfig.include(context, 'configure.zcml', package)
     >>> context.execute_actions()
-    
+
     >>> data = foo.data.pop()
 
     >>> data.args
     (('x', 'blah'), ('y', 0))
-    
+
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/configure.zcml", line 12.2-12.29
 
@@ -221,7 +221,7 @@
 
     >>> data.package is package
     1
-    
+
     >>> data.basepath[-13:]
     'samplepackage'
 
@@ -249,12 +249,12 @@
     >>> path = os.path.join(here, "samplepackage", "foo.zcml")
     >>> xmlconfig.include(context, path)
     >>> context.execute_actions()
-    
+
     >>> data = foo.data.pop()
 
     >>> data.args
     (('x', 'foo'), ('y', 2))
-    
+
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/foo.zcml.in", line 12.2-12.28
 
@@ -263,7 +263,7 @@
         <test:foo x="foo" y="2" />
 
     >>> data.package
-    
+
     >>> data.basepath[-13:]
     'samplepackage'
 
@@ -279,30 +279,30 @@
     >>> path = os.path.join(here, "samplepackage/baz*.zcml")
     >>> xmlconfig.include(context, files=path)
     >>> context.execute_actions()
-    
+
     >>> data = foo.data.pop()
     >>> data.args
     (('x', 'foo'), ('y', 3))
-    
+
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/baz3.zcml", line 5.2-5.28
 
     >>> print clean_info_path(str(data.info))
     File "tests/samplepackage/baz3.zcml", line 5.2-5.28
         <test:foo x="foo" y="3" />
-    
+
     >>> data.package
-    
+
     >>> data.basepath[-13:]
     'samplepackage'
 
     >>> [clean_path(p) for p in data.includepath]
     ['tests/samplepackage/baz3.zcml']
-    
+
     >>> data = foo.data.pop()
     >>> data.args
     (('x', 'foo'), ('y', 2))
-    
+
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/baz2.zcml", line 5.2-5.28
 
@@ -311,7 +311,7 @@
         <test:foo x="foo" y="2" />
 
     >>> data.package
-    
+
     >>> data.basepath[-13:]
     'samplepackage'
 
@@ -335,7 +335,7 @@
       line = line.rstrip()
       if not line:
         continue
-      l = line.find('File "') 
+      l = line.find('File "')
       if l >= 0:
         line = line[:l] + clean_info_path(line[l:])
       r.append(line)
@@ -362,7 +362,7 @@
 
     >>> context = config.ConfigurationMachine()
     >>> xmlconfig.registerCommonDirectives(context)
-    
+
     >>> here = os.path.dirname(__file__)
     >>> path = os.path.join(here, "samplepackage", "bar.zcml")
     >>> xmlconfig.include(context, path)
@@ -398,7 +398,7 @@
       'includepath': ['tests/samplepackage/bar.zcml',
                       'tests/samplepackage/bar2.zcml'],
       'info': 'File "tests/samplepackage/bar2.zcml", line 6.2-6.24'}]
-    
+
     As you can see, there are a number of conflicts (actions with the same
     discriminator).  Some of these can be resolved, but many can't, as
     we'll find if we try to execuse the actions:
@@ -432,7 +432,7 @@
     >>> xmlconfig.include(context, path)
 
     Now, if we look at the actions:
-    
+
     >>> pprint(clean_actions(context.actions))
     [{'discriminator': (('x', 'blah'), ('y', 0)),
       'includepath': ['tests/samplepackage/baro.zcml',
@@ -478,13 +478,13 @@
     (('x', 'blah'), ('y', 0))
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/bar21.zcml", line 3.2-3.24
-    
+
     >>> data = foo.data.pop(0)
     >>> data.args
     (('x', 'blah'), ('y', 2))
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/bar2.zcml", line 5.2-5.24
-    
+
     >>> data = foo.data.pop(0)
     >>> data.args
     (('x', 'blah'), ('y', 1))
@@ -539,7 +539,7 @@
     >>> path = os.path.join(here, "samplepackage", "baro.zcml")
 
     First, process the configuration file:
-    
+
     >>> x = xmlconfig.XMLConfig(path)
 
     Second, call the resulting object to process the actions:
@@ -550,25 +550,25 @@
 
     >>> len(foo.data)
     3
-    
+
     >>> data = foo.data.pop(0)
     >>> data.args
     (('x', 'blah'), ('y', 0))
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/bar21.zcml", line 3.2-3.24
-    
+
     >>> data = foo.data.pop(0)
     >>> data.args
     (('x', 'blah'), ('y', 2))
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/bar2.zcml", line 5.2-5.24
-    
+
     >>> data = foo.data.pop(0)
     >>> data.args
     (('x', 'blah'), ('y', 1))
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/bar2.zcml", line 6.2-6.24
-    
+
     Finally, clean up.
 
     >>> from zope.testing.cleanup import CleanUp
@@ -583,7 +583,7 @@
     >>> import zope.configuration.tests.samplepackage as module
 
     First, process the configuration file:
-    
+
     >>> x = xmlconfig.XMLConfig("baro.zcml", module)
 
     Second, call the resulting object to process the actions:
@@ -594,33 +594,33 @@
 
     >>> len(foo.data)
     3
-    
+
     >>> data = foo.data.pop(0)
     >>> data.args
     (('x', 'blah'), ('y', 0))
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/bar21.zcml", line 3.2-3.24
-    
+
     >>> data = foo.data.pop(0)
     >>> data.args
     (('x', 'blah'), ('y', 2))
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/bar2.zcml", line 5.2-5.24
-    
+
     >>> data = foo.data.pop(0)
     >>> data.args
     (('x', 'blah'), ('y', 1))
     >>> print clean_info_path(`data.info`)
     File "tests/samplepackage/bar2.zcml", line 6.2-6.24
-    
+
     Finally, clean up.
 
     >>> from zope.testing.cleanup import CleanUp
     >>> CleanUp().cleanUp()
     """
-    
 
 
+
 def test_suite():
     return unittest.TestSuite((
         DocTestSuite('zope.configuration.xmlconfig'),

Modified: Zope3/trunk/src/zope/configuration/xmlconfig.py
===================================================================
--- Zope3/trunk/src/zope/configuration/xmlconfig.py	2006-09-03 18:45:51 UTC (rev 69947)
+++ Zope3/trunk/src/zope/configuration/xmlconfig.py	2006-09-03 18:46:38 UTC (rev 69948)
@@ -15,7 +15,7 @@
 
 Note, for a detailed description of the way that conflicting
 configuration actions are resolved, see the detailed example in
-test_includeOverrides in tests/text_xmlconfig.py
+test_includeOverrides in tests/test_xmlconfig.py
 
 $Id$
 """



More information about the Zope3-Checkins mailing list