| org.apache.ojb.junit.OJBTestCase org.apache.ojb.broker.cache.ObjectCacheTest
ObjectCacheTest | public class ObjectCacheTest extends OJBTestCase (Code) | | Do some basic tests using ObjectCache implementations.
author: Armin Waibel author: Thomas Mahler version: $Id: ObjectCacheTest.java,v 1.1.2.2 2005/07/24 23:57:42 arminw Exp $ |
Inner Class :public static class CacheObject implements Serializable | |
Inner Class :public static class TestObjectEmptyCache | |
Inner Class :public static class TestObjectDefaultCache extends TestObjectEmptyCache | |
EXCLUDE_PACKAGE_NOT_EXIST | final static String EXCLUDE_PACKAGE_NOT_EXIST(Code) | | |
YYYtestCacheIsolation | public void YYYtestCacheIsolation() throws Exception(Code) | | This test checks if the caches of two different brokers are properly isolated.
changes made to an object in tx1 should not be visible in tx2 !
TODO: once we work without global cache only (e.g. intern temporary cache), this test should pass!
|
testCacheFilterFunctions | public void testCacheFilterFunctions() throws Exception(Code) | | This test check the 'cacheExcludes' property and try to exclude a whole package from
caching.
throws: Exception - |
testJCSPerClassObjectCacheImplementation | public void testJCSPerClassObjectCacheImplementation() throws Exception(Code) | | Test the JCS cache implementation. In JCS config file the following
properties are set:
jcs.region.org.apache.ojb.broker.cache.ObjectCacheTest$CacheObject.cacheattributes.MaxObjects=3
jcs.region.org.apache.ojb.broker.cache.ObjectCacheTest$CacheObject.cacheattributes.MaxMemoryIdleTimeSeconds=2
jcs.region.org.apache.ojb.broker.cache.ObjectCacheTest$CacheObject.cacheattributes.UseMemoryShrinker=true
jcs.region.org.apache.ojb.broker.cache.ObjectCacheTest$CacheObject.cacheattributes.ShrinkerIntervalSeconds=1
|
testObjectCacheDefaultImpl | public void testObjectCacheDefaultImpl() throws Exception(Code) | | |
testObjectCacheDefaultImplTimeout | public void testObjectCacheDefaultImplTimeout() throws Exception(Code) | | |
testPerClassCache | public void testPerClassCache() throws Exception(Code) | | Test per class ObjectCache declaration. 'TestObjectEmptyCache'
class metadata declare an 'empty ObjectCache' implementation
as cache, CacheObject use the default ObjectCache implementation.
Thus we should found 'CacheObject' instance in cache, but NOT found
'TestObjectEmptyCache' instance.
|
testPerDatabaseCache | public void testPerDatabaseCache()(Code) | | Read a specific jdbc-connction-descriptor at runtime, merge it with current
ConnectionRepository, lookup a specific PersistenceBroker instance, get ObjectCache.
This should be ObjectCacheEmptyImpl, because this is declared at jdbc-connection-descriptor
level.
|
testSimpleObjectCacheFunctions | public void testSimpleObjectCacheFunctions() throws Exception(Code) | | Check base caching functions of some cache implementations.
throws: Exception - |
Methods inherited from org.apache.ojb.junit.OJBTestCase | public void ojbChangeReferenceSetting(Class clazz, String referenceField, boolean autoRetrieve, int autoUpdate, int autoDelete, boolean useProxy)(Code)(Java Doc) public void ojbChangeReferenceSetting(Class clazz, String referenceField, boolean autoRetrieve, boolean autoUpdate, boolean autoDelete, boolean useProxy)(Code)(Java Doc) public boolean ojbSkipKnownIssueProblem()(Code)(Java Doc) public boolean ojbSkipKnownIssueProblem(String message)(Code)(Java Doc) public void ojbSkipTestMessage(String message)(Code)(Java Doc) public void ojbSleep()(Code)(Java Doc) protected void setUp() throws Exception(Code)(Java Doc) protected void tearDown() throws Exception(Code)(Java Doc)
|
|
|