Verifies accounts hash in snapshot tests (#30724)

This commit is contained in:
Brooks 2023-03-15 12:23:44 -04:00 committed by GitHub
parent 65cd55261a
commit a5f86a8212
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 0 deletions

View File

@ -463,6 +463,7 @@ fn test_snapshots_have_expected_epoch_accounts_hash() {
)
.unwrap()
.0;
deserialized_bank.wait_for_initial_accounts_hash_verification_completed_for_tests();
assert_eq!(&deserialized_bank, bank.as_ref());
assert_eq!(

View File

@ -181,6 +181,7 @@ fn restore_from_snapshot(
&Arc::default(),
)
.unwrap();
deserialized_bank.wait_for_initial_accounts_hash_verification_completed_for_tests();
let bank = old_bank_forks.get(deserialized_bank.slot()).unwrap();
assert_eq!(bank.as_ref(), &deserialized_bank);
@ -927,6 +928,7 @@ fn restore_from_snapshots_and_check_banks_are_equal(
None,
&Arc::default(),
)?;
deserialized_bank.wait_for_initial_accounts_hash_verification_completed_for_tests();
assert_eq!(bank, &deserialized_bank);
@ -1143,6 +1145,7 @@ fn test_snapshots_with_background_services(
&exit,
)
.unwrap();
deserialized_bank.wait_for_initial_accounts_hash_verification_completed_for_tests();
assert_eq!(
deserialized_bank.slot(),