[jboss-cvs] JBossAS SVN: r100643 - trunk/testsuite/src/main/org/jboss/test/cluster/defaultcfg/test.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Fri Feb 5 18:53:29 EST 2010


Author: bstansberry at jboss.com
Date: 2010-02-05 18:53:29 -0500 (Fri, 05 Feb 2010)
New Revision: 100643

Modified:
   trunk/testsuite/src/main/org/jboss/test/cluster/defaultcfg/test/CacheManagerUnitTestCase.java
Log:
Don't assume CacheManager.stop() stops caches

Modified: trunk/testsuite/src/main/org/jboss/test/cluster/defaultcfg/test/CacheManagerUnitTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/cluster/defaultcfg/test/CacheManagerUnitTestCase.java	2010-02-05 23:52:28 UTC (rev 100642)
+++ trunk/testsuite/src/main/org/jboss/test/cluster/defaultcfg/test/CacheManagerUnitTestCase.java	2010-02-05 23:53:29 UTC (rev 100643)
@@ -185,10 +185,15 @@
       
       // One release does not cause registry to stop cache
       assertEquals(CacheStatus.STARTED, cache.getCacheStatus());
-      
+
       registry.stop();
       
-      // Now it's stopped
+      // Should still not be stopped
+      assertEquals(CacheStatus.STARTED, cache.getCacheStatus());
+
+      registry.releaseCache(configName);
+
+      // Now it should be stopped
       assertEquals(CacheStatus.DESTROYED, cache.getCacheStatus());
       caches.remove(cache);
       
@@ -278,10 +283,15 @@
       
       // One release does not cause registry to stop cache
       assertEquals(CacheStatus.STARTED, cache.getCache().getCacheStatus());
-      
+
       registry.stop();
-      
-      // Now it's stopped
+
+      // Should still not be stopped
+      assertEquals(CacheStatus.STARTED, cache.getCache().getCacheStatus());
+
+      registry.releaseCache(configName);
+
+      // Now it should be stopped
       assertEquals(CacheStatus.DESTROYED, cache.getCache().getCacheStatus());
       caches.remove(cache);
       




More information about the jboss-cvs-commits mailing list