On 11/20/10 9:21 PM, [email protected] wrote:
> David Glick wrote:
> > On 11/19/10 10:57 PM, Ross Patterson wrote:
> >> Andreas Jung <[email protected]> writes:
> >>
> >>> Ross Patterson wrote:
> >>>
> >>>> Your ZCML doesn't incldue five:registerPackage
> >>> Does not help after adding registerPackage:
> >>>
> >>>
> http://svn.plone.org/svn/collective/Products.EasyNewsletter/trunk/Products/EasyNewsletter/configure.zcml
> >>>
> >>>> nor does your test setup
> >>>> call installProduct.
> >>> installProduct() is of course called in the setup of the layer
> >>> (see base.py).
> >> My bad, missed the installProduct.
> > installProduct is a deferred call just like setupPloneSite and your
> > setup_registration.  So when you call it from within setup_registration,
> > it adds the deferred function too late.  I think it'll work if you put
> > the installProduct line outside of setup_registration.
>
> Right - this works.
>
> Then this documentation is wrong - as it states to call installPackage()
> or installProduct() inside setup_registration().
>
> http://plone.org/documentation/manual/developer-manual/testing/writing-a-plonetestcase-unit-integration-test
It demonstrates calling installProduct outside of the @onsetup function,
and installPackage inside. That is correct.
David
----------              
David Glick
 Web Developer
 [email protected]
 206.286.1235x32

Groundwire: You Are Connected           
 http://groundwire.org          

Online tools and strategies for the environmental movement.  Sign up for 
Groundwire News!
 http://groundwire.org/email-capture

Check out our 2010 Website Benchmarks Report. How do you stack up?
 http://groundwire.org/resources/articles/2010-website-benchmarks-report

_______________________________________________
Product-Developers mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/product-developers

Reply via email to