Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

added test for move()

  • Loading branch information...
commit ca54cd99ff55dc5a27d7e4cdd4ff4ff0eb4a7823 1 parent c1b3018
Bela Ban authored December 16, 2010
12  tests/junit-functional/org/jgroups/tests/RetransmitTableTest.java
@@ -190,6 +190,18 @@ public void testResizeWithPurge2() {
190 190
     }
191 191
 
192 192
 
  193
+    public static void testMove() {
  194
+        RetransmitTable table=new RetransmitTable(3, 10, 0);
  195
+        for(long i=0; i < 50; i++)
  196
+            addAndGet(table, i, "hello-" + i);
  197
+        table.purge(49);
  198
+        assert table.isEmpty();
  199
+        addAndGet(table, 50, "50");
  200
+        assert table.size() == 1;
  201
+        assert table.capacity() == 50;
  202
+    }
  203
+
  204
+
193 205
     public static void testPurge() {
194 206
         RetransmitTable table=new RetransmitTable(5, 10, 0);
195 207
         for(long seqno=0; seqno < 25; seqno++)

0 notes on commit ca54cd9

Please sign in to comment.
Something went wrong with that request. Please try again.