org.shiftone.cache.util
Class TestCaseBase

java.lang.Object
  extended byjunit.framework.Assert
      extended byjunit.framework.TestCase
          extended byorg.shiftone.cache.util.TestCaseBase
All Implemented Interfaces:
junit.framework.Test
Direct Known Subclasses:
FifoCacheTestCase, LfuCacheTestCase, LruCacheTestCase

public abstract class TestCaseBase
extends junit.framework.TestCase

Class TestCaseBase

Version:
$Revision: 1.17 $
Author:
Jeff Drost

Field Summary
(package private) static java.util.Random random
           
 
Constructor Summary
TestCaseBase(java.lang.String name)
          Constructor TestCaseBase
 
Method Summary
abstract  CacheFactory getCacheFactory()
          Method getCacheFactory
 Cache newCache(long timeoutMilliSeconds, int maxSize)
          Method newInstance
static java.lang.String randKey()
          Method randKey
static java.lang.String randValue()
          Method randValue
 void test10000Puts()
          Method test10000Puts
 void test10000Puts99999Gets()
          Method test10000Puts99999Gets
 void test10000UniquePuts()
          Method test10000Puts
 void test1000Puts10000GetsSameKey()
          Method test10000Puts
 void test1Put10000GetsSameKey2Puts()
          Method test1Put10000GetsSameKey10Puts
 void testCacheOfSize1()
          Method testCacheOfSize1
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, setUp, tearDown, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

random

static java.util.Random random
Constructor Detail

TestCaseBase

public TestCaseBase(java.lang.String name)
Constructor TestCaseBase

Parameters:
name -
Method Detail

getCacheFactory

public abstract CacheFactory getCacheFactory()
Method getCacheFactory


newCache

public Cache newCache(long timeoutMilliSeconds,
                      int maxSize)
Method newInstance


test10000UniquePuts

public void test10000UniquePuts()
Method test10000Puts


test10000Puts

public void test10000Puts()
Method test10000Puts


test1000Puts10000GetsSameKey

public void test1000Puts10000GetsSameKey()
Method test10000Puts


test10000Puts99999Gets

public void test10000Puts99999Gets()
Method test10000Puts99999Gets


test1Put10000GetsSameKey2Puts

public void test1Put10000GetsSameKey2Puts()
Method test1Put10000GetsSameKey10Puts


testCacheOfSize1

public void testCacheOfSize1()
Method testCacheOfSize1


randKey

public static java.lang.String randKey()
Method randKey


randValue

public static java.lang.String randValue()
Method randValue