[Zope3-checkins]
SVN: Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py
Make tests pass by passing in the right mock object and
introducing an
Philipp von Weitershausen
philikon at philikon.de
Tue Feb 21 09:38:53 EST 2006
Log message for revision 41727:
Make tests pass by passing in the right mock object and introducing an
import of sys.
Changed:
U Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py
-=-
Modified: Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py
===================================================================
--- Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py 2006-02-21 14:20:05 UTC (rev 41726)
+++ Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py 2006-02-21 14:38:53 UTC (rev 41727)
@@ -46,8 +46,12 @@
bbb_aware=False):
"""Provides a new layer.
+ >>> class Info(object):
+ ... file = u'doctest'
+ ... line = 1
+ ...
>>> class Context(object):
- ... info = u'doc'
+ ... info = Info()
... def __init__(self): self.actions = []
... def action(self, **kw): self.actions.append(kw)
@@ -203,8 +207,12 @@
"""Provides a new skin.
>>> import pprint
+ >>> class Info(object):
+ ... file = u'doctest'
+ ... line = 1
+ ...
>>> class Context(object):
- ... info = u'doc'
+ ... info = Info()
... def __init__(self): self.actions = []
... def action(self, **kw): self.actions.append(kw)
@@ -222,6 +230,7 @@
>>> pprint.pprint(iface.__bases__)
(<InterfaceClass zope.app.publisher.browser.metaconfigure.Layer1>,
<InterfaceClass zope.app.publisher.browser.metaconfigure.Layer2>)
+ >>> import sys
>>> hasattr(sys.modules['zope.app.skins'], 'skin1')
True
More information about the Zope3-Checkins
mailing list