Remove accounts when the fork is removed (#3384)

* Fix test

* Cleanup accounts when the fork is removed

* Update test to check for deleted accounts
This commit is contained in:
Sathish
2019-03-21 17:36:10 -07:00
committed by GitHub
parent dbb145c266
commit 06b0c98c75
3 changed files with 107 additions and 34 deletions

View File

@ -704,7 +704,8 @@ mod test {
#[test]
fn test_handle_new_root() {
let bank0 = Bank::default();
let genesis_block = GenesisBlock::new(10_000).0;
let bank0 = Bank::new(&genesis_block);
let bank_forks = Arc::new(RwLock::new(BankForks::new(0, bank0)));
let mut progress = HashMap::new();
progress.insert(5, (Hash::default(), 0));