Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test(provider): instantiate provider with util function #5534

Merged
merged 1 commit into from
Nov 22, 2023

Conversation

rkrasiuk
Copy link
Member

Description

Instantiate test provider factories with utility function create_test_provider_factory.

@rkrasiuk rkrasiuk added A-db Related to the database C-test A change that impacts how or what we test labels Nov 22, 2023
Comment on lines 514 to 518
#[test]
fn common_history_provider() {
let chain_spec = ChainSpecBuilder::mainnet().build();
let db = create_test_rw_db();
let provider = ProviderFactory::new(db, Arc::new(chain_spec));
let _ = provider.latest();
let factory = create_test_provider_factory();
let _ = factory.latest();
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what does this test do?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's a leftover checking the lifetime bounds of state provider, should be ok to remove in another PR

@rkrasiuk rkrasiuk added this pull request to the merge queue Nov 22, 2023
Merged via the queue into main with commit 5e378b1 Nov 22, 2023
27 checks passed
@rkrasiuk rkrasiuk deleted the rkrasiuk/instantiate-provider-with-util branch November 22, 2023 15:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-db Related to the database C-test A change that impacts how or what we test
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants