[jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Manik Surtani
manik at jboss.org
Tue May 1 18:01:04 EDT 2007
User: msurtani
Date: 07/05/01 18:01:04
Modified: tests/functional/org/jboss/cache/optimistic
NodeInterceptorPutMapTest.java
Log:
Repaired test
Revision Changes Path
1.13 +6 -5 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutMapTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorPutMapTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutMapTest.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -b -r1.12 -r1.13
--- NodeInterceptorPutMapTest.java 7 Feb 2007 22:06:50 -0000 1.12
+++ NodeInterceptorPutMapTest.java 1 May 2007 22:01:04 -0000 1.13
@@ -151,6 +151,7 @@
TestListener listener = new TestListener();
final CacheImpl cache = createCacheWithListener(listener);
+ Fqn f = Fqn.fromString("/one/two");
Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
interceptor.setCache(cache);
@@ -176,12 +177,12 @@
SamplePojo pojo = new SamplePojo(21, "test");
Map temp = new HashMap();
temp.put("key1", pojo);
- cache.put("/one/two", temp);
+ cache.put(f, temp);
Map temp2 = new HashMap();
- cache.put("/one/two", temp2);
+ cache.put(f, temp2, true);
assertEquals(null, dummy.getCalled());
TransactionTable table = cache.getTransactionTable();
@@ -195,11 +196,11 @@
mgr.commit();
//assert what should be the results of our call
assertEquals(3, workspace.getNodes().size());
- assertNotNull(workspace.getNode(Fqn.fromString("/one/two")));
- assertEquals(null, workspace.getNode(Fqn.fromString("/one/two")).get("key1"));
+ assertNotNull(workspace.getNode(f));
+ assertEquals(null, workspace.getNode(f).get("key1"));
assertTrue(entry.getLocks().isEmpty());
assertEquals(2, entry.getModifications().size());
- assertTrue(!cache.exists("/one/two"));
+ assertTrue(!cache.exists(f));
assertEquals(null, dummy.getCalled());
cache.stop();
}
More information about the jboss-cvs-commits
mailing list