136
136
>>> from zope.configuration import xmlconfig
137
137
>>> zcmlcontext = xmlconfig.string("""
138
138
... <configure xmlns:browser="http://namespaces.zope.org/browser"
139
... package="canonical.launchpad">
139
... package="lp.services">
140
140
... <include file="webapp/meta-overrides.zcml" />
141
141
... <browser:page
142
142
... for="lp.testing.IFoo"
200
200
>>> P.page(context, name, facet=facet)
201
201
>>> P.page(context, "OTHER NAME")
203
# This is a pointless test. See pointless test comment above
204
# -- StuartBishop 20060411
207
# <function provideInterface>,
212
# <InterfaceClass zope.publisher.interfaces.browser.IBrowserRequest>,
213
# <InterfaceClass zope.publisher.interfaces.browser.IBrowserRequest>),
214
# <function handler>,
218
# <InterfaceClass zope.publisher.interfaces.browser.IBrowserRequest>),
219
# <InterfaceClass zope.interface.Interface>,
221
# <class 'zope.app.publisher.browser.viewmeta.SimpleLaunchpadViewClass'>,
224
# <function provideInterface>,
229
# <InterfaceClass zope.publisher.interfaces.browser.IBrowserRequest>,
230
# <InterfaceClass zope.publisher.interfaces.browser.IBrowserRequest>),
231
# <function handler>,
235
# <InterfaceClass zope.publisher.interfaces.browser.IBrowserRequest>),
236
# <InterfaceClass zope.interface.Interface>,
238
# <class 'zope.app.publisher.browser.viewmeta.SimpleLaunchpadViewClass'>,
242
203
Look for the SimpleLaunchpadViewClass in the data structure above, and check
243
204
its __launchpad_facetname__ attribute.
261
222
>>> zcmlcontext = xmlconfig.string("""
262
223
... <configure xmlns:browser="http://namespaces.zope.org/browser"
263
... package="canonical.launchpad">
224
... package="lp.services">
264
225
... <include file="webapp/meta-overrides.zcml" />
265
226
... <browser:pages
266
227
... for="lp.testing.IFoo"
355
316
>>> zcmlcontext = xmlconfig.string("""
356
317
... <configure xmlns:browser="http://namespaces.zope.org/browser"
357
... package="canonical.launchpad">
318
... package="lp.services">
358
319
... <include file="webapp/meta-overrides.zcml" />
359
320
... <browser:editform
360
321
... for="lp.testing.IFoo"
438
399
>>> zcmlcontext = xmlconfig.string("""
439
400
... <configure xmlns:browser="http://namespaces.zope.org/browser"
440
... package="canonical.launchpad">
401
... package="lp.services">
441
402
... <include file="webapp/meta-overrides.zcml" />
442
403
... <browser:addform
443
404
... for="lp.testing.IFoo"
518
479
>>> zcmlcontext = xmlconfig.string("""
519
480
... <configure xmlns:browser="http://namespaces.zope.org/browser"
520
... package="canonical.launchpad">
481
... package="lp.services">
521
482
... <include file="webapp/meta-overrides.zcml" />
522
483
... <browser:schemadisplay
523
484
... for="lp.testing.IFoo"
561
522
>>> zcmlcontext = xmlconfig.string("""
562
523
... <configure xmlns="http://namespaces.zope.org/zope"
563
524
... xmlns:browser="http://namespaces.zope.org/browser"
564
... package="canonical.launchpad">
525
... package="lp.services">
565
526
... <include file="webapp/meta.zcml" />
566
527
... <include file="webapp/meta-overrides.zcml" />
567
528
... <facet facet="whole-facet">
634
595
>>> zcmlcontext = xmlconfig.string("""
635
596
... <configure xmlns="http://namespaces.zope.org/zope"
636
597
... i18n_domain="canonical">
637
... <include file="lib/canonical/launchpad/webapp/meta-overrides.zcml" />
598
... <include file="lib/lp/services/webapp/meta-overrides.zcml" />
638
599
... <permission id="foo.bar" title="Foo Bar" access_level="read" />