()
| 59 | } |
| 60 | |
| 61 | @Test |
| 62 | public void uint64AddOption() |
| 63 | throws InterruptedException, RocksDBException { |
| 64 | try (final Options opt = new Options() |
| 65 | .setCreateIfMissing(true) |
| 66 | .setMergeOperatorName("uint64add"); |
| 67 | final RocksDB db = RocksDB.open(opt, |
| 68 | dbFolder.getRoot().getAbsolutePath())) { |
| 69 | // writing (long)100 under key |
| 70 | db.put("key".getBytes(), longToByteArray(100)); |
| 71 | // merge (long)1 under key |
| 72 | db.merge("key".getBytes(), longToByteArray(1)); |
| 73 | |
| 74 | final byte[] value = db.get("key".getBytes()); |
| 75 | final long longValue = longFromByteArray(value); |
| 76 | assertThat(longValue).isEqualTo(101); |
| 77 | } |
| 78 | } |
| 79 | |
| 80 | @Test |
| 81 | public void cFStringOption() |
nothing calls this directly
no test coverage detected