[infinispan-dev] Dependency injection issue

Galder Zamarreno galder.zamarreno at redhat.com
Wed Aug 5 10:39:43 EDT 2009



On 08/05/2009 04:38 PM, Manik Surtani wrote:
> Yes, that is a good idea.
>
> BaseCacheStoreTest is a unit test, not a functional one. Perhaps create
> a BaseCacheStoreFunctionalTest for testTwoCachesSameCacheStore(), and
> make sure all cache store impls extend this test?

Yeah, sounds perfect.

Btw, I've just run a quick test where I've added cache.start() methods 
instead of the VAM.start() calls in testTwoCachesSameCacheStore() and 
the test fails, so the issue Mircea had is 
https://jira.jboss.org/jira/browse/ISPN-148

In fact, I'll take the 148 opportunity to implement what you suggested 
above.

>
> Cheers
> Manik
>
> On 5 Aug 2009, at 15:33, Galder Zamarreno wrote:
>
>> One thing to note about BaseCacheStoreTest is that all the tests
>> within it work directly with CacheStore and not Cache or CacheManager.
>>
>> So, for tests related to cache stores where the test interacts with
>> Cache/CacheManager interface, I'd put them in a separate class.
>>
>> On 08/05/2009 04:26 PM, Galder Zamarreno wrote:
>>> Mircea, if you were to call cache.start() in that
>>> testTwoCachesSameCacheStore, would that work?
>>>
>>> I've just seen an user report a similar whereby VAM's @Start method is
>>> not being called in spite of them calling cache.start()
>>>
>>> https://jira.jboss.org/jira/browse/ISPN-148
>>>
>>> On 08/05/2009 09:55 AM, Manik Surtani wrote:
>>>> That's because you're not calling cache.start() in the test. :-) It
>>>> is an isolated test to test the CacheStore. So yes, manually calling
>>>> start() on the Marshaller is the correct approach if you need a
>>>> start()'ed marshaller.
>>>>
>>>> Cheers
>>>> Manik
>>>>
>>>> On 4 Aug 2009, at 20:01, Mircea Markus wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> VersionAwareMarshaller.start does not get called and I don't know
>>>>> why, can you give me an helping hand on this?
>>>>> See BaseCacheStoreTest.testTwoCachesSameCacheStore, the TODO there.
>>>>>
>>>>> Cheers,
>>>>> Mircea
>>>>>
>>>>>
>>>> --
>>>> Manik Surtani
>>>> manik at jboss.org
>>>> Lead, Infinispan
>>>> Lead, JBoss Cache
>>>> http://www.infinispan.org
>>>> http://www.jbosscache.org
>>>>
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> infinispan-dev mailing list
>>>> infinispan-dev at lists.jboss.org
>>>> https://lists.jboss.org/mailman/listinfo/infinispan-dev
>>>
>>
>> --
>> Galder Zamarreño
>> Sr. Software Engineer
>> Infinispan, JBoss Cache
>
> --
> Manik Surtani
> manik at jboss.org
> Lead, Infinispan
> Lead, JBoss Cache
> http://www.infinispan.org
> http://www.jbosscache.org
>
>
>
>
>

-- 
Galder Zamarreño
Sr. Software Engineer
Infinispan, JBoss Cache



More information about the infinispan-dev mailing list