Skip to content

Commit

Permalink
pr
Browse files Browse the repository at this point in the history
  • Loading branch information
HaoranYi committed Dec 16, 2024
1 parent ebcee80 commit 0eb57e4
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion accounts-db/src/accounts_db/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8104,7 +8104,14 @@ fn test_clean_old_storages_with_reclaims_rooted() {
);
accounts_db.add_root_and_flush_write_cache(slot);
}
// for this test, `new_slot` must not be in `dirty_stores`.
// For this test, `new_slot` must **not** be in `dirty_stores`. There are
// two ways to drive `clean`: 1) by "uncleaned" pubkeys, or 2) by "dirty"
// stores. This test is to simulate the case of normal bank rooting process
// to kick off clean. In normal bank rooting process, the "clean" is driven
// by computing the delta hash of the rooted slot. In computing delta hash,
// we directly pick up the pubkeys in the store and set them on
// `cleaned_pubkeys` for clean. We are *not* setting `dirty_store` for this
// case.
assert!(!accounts_db.dirty_stores.contains_key(&new_slot));

// ensure the slot list for `pubkey` has both the old and new slots
Expand Down

0 comments on commit 0eb57e4

Please sign in to comment.