From 32ee88b4d7aefb890d3c366125a45138c6eb7f40 Mon Sep 17 00:00:00 2001 From: leventov Date: Sun, 25 Jan 2015 08:58:52 +0700 Subject: [PATCH] Removed CHMUseCases tests which make little sense with new contexts --- .../chronicle/map/CHMUseCasesTest.java | 48 ------------------- 1 file changed, 48 deletions(-) diff --git a/src/test/java/net/openhft/chronicle/map/CHMUseCasesTest.java b/src/test/java/net/openhft/chronicle/map/CHMUseCasesTest.java index 3ebc2341f..36a9db4d3 100644 --- a/src/test/java/net/openhft/chronicle/map/CHMUseCasesTest.java +++ b/src/test/java/net/openhft/chronicle/map/CHMUseCasesTest.java @@ -656,28 +656,6 @@ public class CHMUseCasesTest { } } - @Test - public void testGetUsingWithCharSequenceNoValue() throws IOException { - ChronicleMapBuilder builder = ChronicleMapBuilder - .of(CharSequence.class, CharSequence.class); - - if (typeOfMap == TypeOfMap.STATELESS) - return; // context supported by the STATELESS client - - try (ChronicleMap map = newInstance(builder)) { - - try (MapKeyContext c = map.context("1")) { - CharSequence value = c.get(); - assertTrue(value instanceof StringBuilder); - ((StringBuilder) value).append("Hello World"); - } - - assertEquals(null, map.get("1")); - mapChecks(); - } - } - - @Test public void testGetUsingWithIntValueNoValue() throws IOException { @@ -699,32 +677,6 @@ public class CHMUseCasesTest { } } - - @Test(expected = IllegalStateException.class) - public void testAcquireUsingWithIntValueNoValue() throws IOException { - - if (typeOfMap == TypeOfMap.STATELESS) - throw new IllegalStateException(); // acquireContext supported by the STATELESS - - - ChronicleMapBuilder builder = ChronicleMapBuilder - .of(CharSequence.class, IntValue.class); - - try (ChronicleMap map = newInstance(builder)) { - - try (MapKeyContext c = map.context("1")) { - c.updateLock().lock(); - IntValue value = c.get(); - assertTrue(value instanceof IntValue); - value.setValue(1); - } - - assertEquals(null, map.get("1")); - mapChecks(); - } - } - - @Test(expected = IllegalArgumentException.class) public void testAcquireUsingImmutableUsing() throws IOException {