public void Set_restore_get() { SnapshotableDb db = new SnapshotableDb(new MemDb()); db.Set(_hash1, _bytes1); db.Restore(-1); byte[] getResult = db.Get(_hash1); Assert.AreEqual(null, getResult); }
public void Set_commit_delete_restore_get() { SnapshotableDb db = new SnapshotableDb(new MemDb()); db.Set(_hash1, _bytes1); db.Commit(Frontier.Instance); db.Remove(_hash1); db.Restore(-1); byte[] getResult = db.Get(_hash1); Assert.AreEqual(_bytes1, getResult); }