HCOLL-216 added removeLater

This commit is contained in:
Rob Austin
2014-11-25 14:27:25 +00:00
parent abcf1fabc4
commit 70656a83b9
7 changed files with 203 additions and 89 deletions
@@ -448,6 +448,27 @@ public class StatelessClientTest {
}
@Test
public void testRemoveLater() throws IOException,
InterruptedException, ExecutionException {
try (ChronicleMap<Integer, CharSequence> serverMap = ChronicleMapBuilder.of(Integer.class, CharSequence.class)
.replication((byte) 2, TcpTransportAndNetworkConfig.of(8056)).create()) {
try (ChronicleMap<Integer, CharSequence> statelessMap = ChronicleMapBuilder.of(Integer
.class, CharSequence.class)
.statelessClient(new InetSocketAddress("localhost", 8056)).create()) {
statelessMap.put(1, "some value");
statelessMap.removeLater(1).get();
Assert.assertEquals(null, statelessMap.get(1));
Assert.assertEquals(0, statelessMap.size());
}
}
}
@Test
public void testEquals() throws IOException, InterruptedException {