[jboss-cvs] JBossCache/tests/functional/org/jboss/cache/eviction ...

Manik Surtani msurtani at jboss.com
Thu Jan 18 11:55:19 EST 2007


  User: msurtani
  Date: 07/01/18 11:55:19

  Modified:    tests/functional/org/jboss/cache/eviction      
                        RegionManagerTest.java MRUAlgorithmTest.java
                        FIFOAlgorithmTest.java LRUAlgorithmTest.java
                        DummyEvictionPolicy.java
                        ElementSizeAlgorithmTest.java
  Log:
  JBCACHE-889
  
  Revision  Changes    Path
  1.20      +2 -2      JBossCache/tests/functional/org/jboss/cache/eviction/RegionManagerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionManagerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/RegionManagerTest.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- RegionManagerTest.java	11 Jan 2007 13:49:05 -0000	1.19
  +++ RegionManagerTest.java	18 Jan 2007 16:55:19 -0000	1.20
  @@ -19,7 +19,7 @@
    *
    * @author Ben Wang, Feb 11, 2004
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.19 $
  + * @version $Revision: 1.20 $
    */
   public class RegionManagerTest extends TestCase
   {
  @@ -105,7 +105,7 @@
            // This is ok. Should throw an runtime exception
            return;
         }
  -      fail("If we don't configure the default region, we should throw a RTE!");
  +      fail("If we don't setCache the default region, we should throw a RTE!");
      }
   
      public void testGetRegion()
  
  
  
  1.5       +3 -3      JBossCache/tests/functional/org/jboss/cache/eviction/MRUAlgorithmTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MRUAlgorithmTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/MRUAlgorithmTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- MRUAlgorithmTest.java	14 Nov 2006 14:17:10 -0000	1.4
  +++ MRUAlgorithmTest.java	18 Jan 2007 16:55:19 -0000	1.5
  @@ -8,14 +8,14 @@
   
   import junit.framework.TestCase;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.RegionManager;
   import org.jboss.cache.Region;
  +import org.jboss.cache.RegionManager;
   
   /**
    * Unit tests for MRUAlgorithm.
    *
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    */
   public class MRUAlgorithmTest extends TestCase
   {
  @@ -27,7 +27,7 @@
         super.setUp();
         algorithm = new MRUAlgorithm();
         MRUConfiguration config = new MRUConfiguration();
  -      // We have to configure maxNodes!!
  +      // We have to setCache maxNodes!!
         config.setMaxNodes(0);
         config.setEvictionPolicyClass(DummyEvictionPolicy.class.getName());
         regionManager = new RegionManager();
  
  
  
  1.7       +2 -2      JBossCache/tests/functional/org/jboss/cache/eviction/FIFOAlgorithmTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FIFOAlgorithmTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/FIFOAlgorithmTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- FIFOAlgorithmTest.java	14 Nov 2006 14:17:10 -0000	1.6
  +++ FIFOAlgorithmTest.java	18 Jan 2007 16:55:19 -0000	1.7
  @@ -17,7 +17,7 @@
    * Unit tests for FIFOAlgorithm.
    *
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class FIFOAlgorithmTest extends TestCase
   {
  @@ -36,7 +36,7 @@
   
         algo = new FIFOAlgorithm();
         FIFOConfiguration config = new FIFOConfiguration();
  -      // We have to configure maxNodes!!
  +      // We have to setCache maxNodes!!
         config.setMaxNodes(0);
         regionManager = new RegionManager();
         config.setEvictionPolicyClass(DummyEvictionPolicy.class.getName());
  
  
  
  1.9       +3 -4      JBossCache/tests/functional/org/jboss/cache/eviction/LRUAlgorithmTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LRUAlgorithmTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/LRUAlgorithmTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- LRUAlgorithmTest.java	20 Nov 2006 23:32:49 -0000	1.8
  +++ LRUAlgorithmTest.java	18 Jan 2007 16:55:19 -0000	1.9
  @@ -3,12 +3,11 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.RegionManager;
   import org.jboss.cache.Region;
  +import org.jboss.cache.RegionManager;
   import org.jboss.cache.misc.TestingUtil;
   
   /**
  @@ -39,7 +38,7 @@
         algo_ = new LRUAlgorithm();
         config_ = new LRUConfiguration();
         config_.setEvictionPolicyClass(DummyEvictionPolicy.class.getName());
  -      // We have to configure timeToLiveSeconds!!
  +      // We have to setCache timeToLiveSeconds!!
         config_.setTimeToLiveSeconds(0);
         
         regionManager_ = new RegionManager();
  
  
  
  1.4       +4 -4      JBossCache/tests/functional/org/jboss/cache/eviction/DummyEvictionPolicy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DummyEvictionPolicy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/DummyEvictionPolicy.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- DummyEvictionPolicy.java	30 Dec 2006 17:49:58 -0000	1.3
  +++ DummyEvictionPolicy.java	18 Jan 2007 16:55:19 -0000	1.4
  @@ -1,6 +1,6 @@
   package org.jboss.cache.eviction;
   
  -import org.jboss.cache.CacheImpl;
  +import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
   
   /**
  @@ -19,7 +19,7 @@
         return 0;  //To change body of implemented methods use File | Settings | File Templates.
      }
   
  -   public void configure(CacheImpl cache)
  +   public void setCache(CacheSPI cache)
      {
         // no op
      }
  @@ -30,9 +30,9 @@
         return null;
      }
   
  -   public Class getEvictionConfigurationClass()
  +   public Class<? extends EvictionPolicyConfig> getEvictionConfigurationClass()
      {
  -      return null;  //To change body of implemented methods use File | Settings | File Templates.
  +      return null;
      }
   
   
  
  
  
  1.5       +2 -2      JBossCache/tests/functional/org/jboss/cache/eviction/ElementSizeAlgorithmTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ElementSizeAlgorithmTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ElementSizeAlgorithmTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ElementSizeAlgorithmTest.java	14 Nov 2006 14:17:10 -0000	1.4
  +++ ElementSizeAlgorithmTest.java	18 Jan 2007 16:55:19 -0000	1.5
  @@ -15,7 +15,7 @@
   
   /**
    * @author Daniel Huang
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    */
   public class ElementSizeAlgorithmTest extends TestCase
   {
  @@ -34,7 +34,7 @@
         algo = new ElementSizeAlgorithm();
         regionManager = new RegionManager();
         ElementSizeConfiguration config = new ElementSizeConfiguration();
  -      // We have to configure maxElementsPerNode!!
  +      // We have to setCache maxElementsPerNode!!
         config.setMaxElementsPerNode(0);
         config.setEvictionPolicyClass(DummyEvictionPolicy.class.getName());
         regionManager.getRegion("/a/b", true).setEvictionPolicy(config);
  
  
  



More information about the jboss-cvs-commits mailing list