MCPcopy Create free account
hub / github.com/cruppstahl/upscaledb / testGetDuplicateCount

Method testGetDuplicateCount

java/unittests/CursorTest.java:318–335  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

316 }
317
318 public void testGetDuplicateCount() {
319 byte[] key = new byte[10];
320 byte[] record = new byte[10];
321 try {
322 Cursor c = new Cursor(m_db);
323 c.insert(key, record, Const.UPS_DUPLICATE);
324 assertEquals(1, c.getDuplicateCount());
325 record[0] = 0x14;
326 c.insert(key, record, Const.UPS_DUPLICATE);
327 assertEquals(2, c.getDuplicateCount());
328 record[0] = 0x15;
329 c.insert(key, record, Const.UPS_DUPLICATE);
330 assertEquals(3, c.getDuplicateCount());
331 }
332 catch (DatabaseException err) {
333 fail("DatabaseException " + err.getMessage());
334 }
335 }
336
337 public void testSetComparator() throws Exception {
338 byte[] k = new byte[5];

Callers

nothing calls this directly

Calls 3

insertMethod · 0.95
getDuplicateCountMethod · 0.95
getMessageMethod · 0.45

Tested by

no test coverage detected