program-test: Add ability to warp to the future (#14998)

* program-test: Add ability to warp to the future

* Make `start_local_server` take by value

* Remove clear_invoke_context
This commit is contained in:
Jon Cinque
2021-02-03 23:31:36 +01:00
committed by GitHub
parent ebbaa1f8ea
commit 8e93a784f3
8 changed files with 234 additions and 25 deletions

View File

@ -195,6 +195,13 @@ impl BlockCommitmentCache {
self.commitment_slots.slot = slot;
self.commitment_slots.root = slot;
}
pub fn set_all_slots(&mut self, slot: Slot, root: Slot) {
self.commitment_slots.slot = slot;
self.commitment_slots.highest_confirmed_slot = slot;
self.commitment_slots.root = root;
self.commitment_slots.highest_confirmed_root = root;
}
}
#[derive(Default, Clone, Copy)]