HCOLL-222 added failing test - map.put() throwing and NPE when putting a LongValue$$Native

This commit is contained in:
Rob Austin
2014-11-28 11:34:55 +00:00
parent 68c66d1094
commit e69d204c90
4 changed files with 45 additions and 14 deletions
@@ -191,7 +191,17 @@ public class ChronicleMapImportExportTest {
.create()) {
expected.put("hello", new LongValue$$Native());
ChronicleMapBuilder<CharSequence, LongValue> builder = ChronicleMapBuilder
.of(CharSequence.class, LongValue.class)
.entries(1000)
.entrySize(16);
LongValue value = new LongValue$$Native();
expected.put("hello", value);
expected.getAll(file);
@@ -1358,13 +1358,13 @@ public class ChronicleMapTest {
@Test
public void equalsTest() throws IOException {
final ChronicleMap<Integer, String> map1 = OnHeapUpdatableChronicleMapBuilder
final ChronicleMap<Integer, String> map1 = ChronicleMapBuilder
.of(Integer.class, String.class).create();
map1.put(1, "one");
map1.put(2, "two");
final ChronicleMap<Integer, String> map2 = OnHeapUpdatableChronicleMapBuilder
final ChronicleMap<Integer, String> map2 = ChronicleMapBuilder
.of(Integer.class, String.class).create();
map2.put(1, "one");
@@ -1406,6 +1406,20 @@ public class ChronicleMapTest {
}
@Ignore("JIRA raised for failing test HCOLL-222")
@Test
public void testPutLongValue() throws IOException {
final ChronicleMapBuilder<CharSequence, LongValue> builder = ChronicleMapBuilder
.of(CharSequence.class, LongValue.class)
.entries(1000)
.entrySize(16);
final ChronicleMap<CharSequence, LongValue> map = builder.create();
LongValue value = nativeLongValue();
map.put("x", value);
}
@Test
public void testOffheapAcquireUsingLocked() throws IOException {
ChronicleMapBuilder<CharSequence, LongValue> builder = ChronicleMapBuilder