[jboss-cvs] JBossCache/tests/functional/org/jboss/cache/loader ...
Manik Surtani
msurtani at jboss.com
Thu Jul 20 06:31:30 EDT 2006
User: msurtani
Date: 06/07/20 06:31:30
Modified: tests/functional/org/jboss/cache/loader
FileCacheLoaderTest.java
JDBCCacheLoaderDerbyDSTest.java
RpcDelegatingCacheLoaderTests.java
Log:
Fixed some broken UTs to use the new xml parsers, cache factories, etc.
Revision Changes Path
1.8 +1 -1 JBossCache/tests/functional/org/jboss/cache/loader/FileCacheLoaderTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: FileCacheLoaderTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/FileCacheLoaderTest.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- FileCacheLoaderTest.java 24 May 2006 05:47:43 -0000 1.7
+++ FileCacheLoaderTest.java 20 Jul 2006 10:31:30 -0000 1.8
@@ -12,7 +12,7 @@
public class FileCacheLoaderTest extends ExtendedCacheLoaderTestsBase {
protected void configureCache() throws Exception {
- cache.setCacheLoaderConfiguration(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.FileCacheLoader", "", false, true, false));
+ cache.getConfiguration().setCacheLoaderConfiguration(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.FileCacheLoader", "", false, true, false));
}
public static Test suite() {
1.2 +2 -4 JBossCache/tests/functional/org/jboss/cache/loader/JDBCCacheLoaderDerbyDSTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: JDBCCacheLoaderDerbyDSTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/JDBCCacheLoaderDerbyDSTest.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -b -r1.1 -r1.2
--- JDBCCacheLoaderDerbyDSTest.java 15 Feb 2006 15:39:50 -0000 1.1
+++ JDBCCacheLoaderDerbyDSTest.java 20 Jul 2006 10:31:30 -0000 1.2
@@ -15,8 +15,6 @@
import javax.naming.Context;
import javax.naming.InitialContext;
import javax.naming.NameNotFoundException;
-
-import java.util.List;
import java.util.Properties;
/**
* This test runs cache loader tests using Database as the cache loader store.
@@ -28,7 +26,7 @@
* must be in the lib directory for this test to run successfuly
*
* @author <a href="hmesha at novell.com">Hany Mesha</a>
- * @version <tt>$Revision: 1.1 $</tt>
+ * @version <tt>$Revision: 1.2 $</tt>
*/
public class JDBCCacheLoaderDerbyDSTest
extends CacheLoaderTestsBase
@@ -72,7 +70,7 @@
"cache.jdbc.node.type=" + prop.getProperty("cache.jdbc.node.type");
- cache.setCacheLoaderConfiguration( getSingleCacheLoaderConfig("", "org.jboss.cache.loader.JDBCCacheLoader", props, false, true, false) );
+ cache.getConfiguration().setCacheLoaderConfiguration( getSingleCacheLoaderConfig("", "org.jboss.cache.loader.JDBCCacheLoader", props, false, true, false) );
cache.createService();
1.6 +9 -6 JBossCache/tests/functional/org/jboss/cache/loader/RpcDelegatingCacheLoaderTests.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: RpcDelegatingCacheLoaderTests.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/RpcDelegatingCacheLoaderTests.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -b -r1.5 -r1.6
--- RpcDelegatingCacheLoaderTests.java 5 May 2006 12:06:58 -0000 1.5
+++ RpcDelegatingCacheLoaderTests.java 20 Jul 2006 10:31:30 -0000 1.6
@@ -2,13 +2,14 @@
import org.jboss.cache.Fqn;
import org.jboss.cache.TreeCache;
+import org.jboss.cache.config.Configuration;
import org.jboss.cache.misc.TestingUtil;
import org.jboss.cache.xml.XmlHelper;
import org.w3c.dom.Element;
/**
* @author Bela Ban
- * @version $Id: RpcDelegatingCacheLoaderTests.java,v 1.5 2006/05/05 12:06:58 msurtani Exp $
+ * @version $Id: RpcDelegatingCacheLoaderTests.java,v 1.6 2006/07/20 10:31:30 msurtani Exp $
*/
public class RpcDelegatingCacheLoaderTests {
TreeCache cache;
@@ -44,11 +45,13 @@
}
private void start(boolean client) throws Exception {
- cache=new TreeCache("test-cluster", null, 3000);
- cache.setCacheMode(TreeCache.REPL_ASYNC);
- cache.setFetchInMemoryState(true);
- cache.setCacheLoaderConfiguration(getCacheLoaderConfig());
- cache.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
+ cache=new TreeCache();
+ cache.getConfiguration().setClusterName("test-cluster");
+ cache.getConfiguration().setInitialStateRetrievalTimeout(3000);
+ cache.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_ASYNC);
+ cache.getConfiguration().setFetchInMemoryState(true);
+ cache.getConfiguration().setCacheLoaderConfiguration(getCacheLoaderConfig());
+ cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
cache.startService();
if(client == false) {
More information about the jboss-cvs-commits
mailing list