anchor.diff:      NewDb = ?TEST_DB:set_entry(Db, db_entry:inc_readlock(Entry)),
       TLogEntry = tx_tlog:new_entry(rdht_tx_read, "key", 1, value, 1, ?value, "val"),
       CommitDb = rdht_tx_read:commit(NewDb, TLogEntry, ?prepared, 1, 2),
  -    SnapEntry = ?TEST_DB:get_snapshot_entry(CommitDb, "key"),
  -    ?equals({false, {"key", empty_val, false, 0, -1}}, SnapEntry), % no entry in snap db
  -    LiveEntry = ?TEST_DB:get_entry2(CommitDb, "key"),
  -    ?equals({true, {"key", "val", false, 0, 1}}, LiveEntry), % no readlocks in live db
  +    ?equals(?TEST_DB:get_snapshot_entry(CommitDb, "key"),
  +            {false, {"key", empty_val, false, 0, -1}}), % no entry in snap db
  +    ?equals(?TEST_DB:get_entry2(CommitDb, "key"),
  +            {true, {"key", "val", false, 0, 1}}), % no readlocks in live db
       ok.
   
   % "new" transaction -> changes only on live db, snapshot db remains untouched
  
positive.code:     Db = ?TEST_DB:set_entry(Db, db_entry:new("key", "val", 1)),
      Db = ?TEST_DB:set_entry(Db, db_entry:new("123", "456", 0)),
      Db = ?TEST_DB:copy_value_to_snapshot_table(Db, "foo"),
      ?equals({false, {"key", empty_val, false, 0, -1}}, ?TEST_DB:get_snapshot_entry(Db, "key")),
      ?equals({false, {"123", empty_val, false, 0, -1}}, ?TEST_DB:get_snapshot_entry(Db, "123")),
      ?equals({false, {"bar", empty_val, false, 0, -1}}, ?TEST_DB:get_snapshot_entry(Db, "bar")),
      ?equals({true, {"foo", "bar", false, 0, 0}}, ?TEST_DB:get_snapshot_entry(Db, "foo")),
      ok.
  
  -spec test_set_get_for_snapshot_table(any()) -> ok.
  
negative.code:     NewDb = ?TEST_DB:set_snapshot_entry(TmpDb, db_entry:inc_readlock(Entry)),
      TLogEntry = tx_tlog:new_entry(rdht_tx_read, "key", 1, value, 2, ?value, "val"),
      CommitDb = rdht_tx_read:commit(NewDb, TLogEntry, ?prepared, 2, 2),
      ?equals(?TEST_DB:get_snapshot_entry(CommitDb, "key"),
              {true, {"key", "val", false, 1, 1}}), % readlock in snap db
      ?equals(?TEST_DB:get_entry2(CommitDb, "key"),
              {true, {"key", "val", false, 0, 1}}), % no readlocks in live db
      ok.
  
  % in rdht_tx_read, abort equals commit, so abort doesn't have to be tested!
  