[Zope-CMF] unit test weirdness.
Thu, 20 Feb 2003 10:04:19 -0600
> *That* is the evil part. $SOFTWARE_HOME/lib/python/Products should
> *not* contain "third-party" products; those should be installed either
> into $INSTANCE_HOME/Products or into a "shared" products directory
> (using the PRODUCTS_PATH variable).
> Otherwise you muddy what needs to be done to upgrade Zope itself.
[This sets off a big light bulb for me!]
Tres, thanks for this feedback. This is exactly the kick in the pants I
needed to get over my laziness about this particular issue. It didn't occur
to me that my tendency to clutter SOFTWARE_HOME was the stumbling block.
(I've been assuming that the *only* reason to use INSTANCE_HOME is if I want
multiple instances. What you're saying--and it makes perfect sense--is that
even if I have only a single Zope instance, from a configuration management
point of view I should still use INSTANCE_HOME. Presumably, then, this
applies to the CMF Products as well? Doh, I look in CMF/INSTALL.txt and it
says to copy/move/link them to INSTANCE_HOME. Double Doh!) I assume what
this means is that if I install my products into INSTANCE_HOME, then I need
some way for Zope to *know about* my product when running tests. And
unraveling *that* is essentially the "machinery" you were referring to?
I am but an egg.
> If you want to redistribute your product, you must not assume that it
> will be installed into the SOFTWARE_HOME.
Got it. Thanks!
> I think we can update the tests to be compatible with 2.6.1, using the
> 'try: Zope.setup()' bit. We *won't* be updating them to remove the
> 'import Zope'.
Sounds good to me.