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(blockifier): estimate_minimal_gas_vector depends on GasVectorComputationMode #776

Merged
merged 1 commit into from
Sep 15, 2024

Conversation

aner-starkware
Copy link
Contributor

@aner-starkware aner-starkware commented Sep 15, 2024

This change is Reviewable

@aner-starkware aner-starkware self-assigned this Sep 15, 2024
Copy link

codecov bot commented Sep 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 70.59%. Comparing base (d39e13b) to head (6785d32).
Report is 6 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #776      +/-   ##
==========================================
- Coverage   76.17%   70.59%   -5.58%     
==========================================
  Files         359       88     -271     
  Lines       38294    11053   -27241     
  Branches    38294    11053   -27241     
==========================================
- Hits        29169     7803   -21366     
+ Misses       6796     2862    -3934     
+ Partials     2329      388    -1941     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@dorimedini-starkware dorimedini-starkware left a comment

Choose a reason for hiding this comment

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

Reviewed 2 of 2 files at r1, all commit messages.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @aner-starkware and @nimrod-starkware)


crates/blockifier/src/transaction/transactions_test.rs line 829 at r1 (raw file):

#[rstest]
fn test_estimate_minimal_gas_vector(
    mut block_context: BlockContext,

if you do this, can you remove the let block_context = &block_context; below?

Suggestion:

block_context: &mut BlockContext,

crates/blockifier/src/transaction/transactions_test.rs line 865 at r1 (raw file):

    } else {
        assert_eq!(minimal_l1_data_gas, 0);
    }

equivalent, and hopefully less lines

Suggestion:

    assert_eq!(minimal_l2_gas > 0, gas_vector_computation_mode == GasVectorComputationMode::All);
    assert_eq!(minimal_l1_data_gas > 0, use_kzg_da);

@aner-starkware aner-starkware force-pushed the aner/test_estimate_minimal_gas_vector branch from 6577e3c to 6785d32 Compare September 15, 2024 12:10
Copy link
Contributor Author

@aner-starkware aner-starkware left a comment

Choose a reason for hiding this comment

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

Reviewable status: 1 of 2 files reviewed, 2 unresolved discussions (waiting on @dorimedini-starkware and @nimrod-starkware)


crates/blockifier/src/transaction/transactions_test.rs line 829 at r1 (raw file):

Previously, dorimedini-starkware wrote…

if you do this, can you remove the let block_context = &block_context; below?

The compiler is not a fan of this...


crates/blockifier/src/transaction/transactions_test.rs line 865 at r1 (raw file):

Previously, dorimedini-starkware wrote…

equivalent, and hopefully less lines

Nice! Done.

Copy link
Collaborator

@dorimedini-starkware dorimedini-starkware left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 1 of 1 files at r2, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @nimrod-starkware)

@aner-starkware aner-starkware merged commit d5d44a4 into main Sep 15, 2024
16 checks passed
@aner-starkware aner-starkware deleted the aner/test_estimate_minimal_gas_vector branch September 15, 2024 12:26
@github-actions github-actions bot locked and limited conversation to collaborators Sep 18, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants