[Zope-CMF] Re: [dev] writing tests for CMF 2.1

Philipp von Weitershausen philipp at weitershausen.de
Wed Nov 8 08:44:09 EST 2006


yuppie wrote:
> Since CMF 2.0 I did a lot of test refactoring, changing the ways CMF 
> tests are set up. Goal was to use more generic and up to date testing 
> patterns, making it easier to write new tests.
> 
> Here is an overview what changed:
> 
> 
> ZopeTestCase.app()
> ------------------
> 
> All tests that depend on a running Zope application use now 
> ZopeTestCase's ZopeLite app. It is not compatible with Zope2.app(), so 
> don't use Zope2.app() anymore. ZopeLite doesn't start up Products by 
> default, you have to specify required Products explicitly using 
> ZopeTestCase.installProduct(). Not each Product has to be initialized 
> that way. Don't initialize Five that way - ZCML is set up differently.
> 
> 
> Layers
> ------
> 
> ZCML is set up using test layers. Their setUp() and tearDown() methods 
> are only run once for all tests in the layer.

Woooohooooo!


-- 
http://worldcookery.com -- Professional Zope documentation and training



More information about the Zope-CMF mailing list