cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Leszek Gawron <>
Subject Re: svn commit: r582862 - /cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/src/test/resources/org/apache/cocoon/template/jxtg/JXTemplateGeneratorTestCase.spring.xml
Date Mon, 08 Oct 2007 21:37:19 GMT
Grzegorz Kossakowski wrote:
> pisze:
>> Author: lgawron
>> Date: Mon Oct  8 09:17:27 2007
>> New Revision: 582862
>> URL:
>> Log:
>> use springified version of cocoon store
> Do you think we you need real implementation of store for testing?
> What about using mock objects?

The store itself is not that heavy to mock it. Anyway the purpose of 
mocking IMO is:

- provide parts of the environment you do not have (http request, 
response, servlet context)
- test interaction between the tested component and it's dependencies 
(like testing if the cocoon template actually registers proper store 

It is way less important in this case to reduce dependencies as they are 
already in place. It's way easier to use store as it is than to create 
and debug a mock that provides a proper functionality.

Leszek Gawron               
CTO at MobileBox Ltd.

View raw message