Skip to content

Commit

Permalink
fix(cancun): tweak ranges in integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Nashtare committed Jul 10, 2024
1 parent ddca6be commit d2cdae0
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
2 changes: 1 addition & 1 deletion evm_arithmetization/tests/empty_txn_list.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ fn test_empty_txn_list() -> anyhow::Result<()> {
let all_circuits = AllRecursiveCircuits::<F, C, D>::new(
&all_stark,
// Minimal ranges to prove an empty list
&[16..17, 11..13, 13..15, 14..15, 9..10, 12..13, 17..18],
&[16..17, 8..9, 13..15, 14..15, 9..10, 12..13, 17..18],
&config,
);

Expand Down
17 changes: 13 additions & 4 deletions evm_arithmetization/tests/log_opcode.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ use evm_arithmetization::generation::{GenerationInputs, TrieInputs};
use evm_arithmetization::proof::{BlockHashes, BlockMetadata, TrieRoots};
use evm_arithmetization::prover::prove;
use evm_arithmetization::testing_utils::{
beacon_roots_account_nibbles, beacon_roots_contract_from_storage, init_logger,
preinitialized_state_and_storage_tries, update_beacon_roots_account_storage,
BEACON_ROOTS_CONTRACT_ADDRESS_HASHED,
beacon_roots_account_nibbles, beacon_roots_contract_from_storage, ger_account_nibbles,
init_logger, preinitialized_state_and_storage_tries, update_beacon_roots_account_storage,
BEACON_ROOTS_CONTRACT_ADDRESS_HASHED, GLOBAL_EXIT_ROOT_ACCOUNT,
};
use evm_arithmetization::verifier::verify_proof;
use evm_arithmetization::{AllRecursiveCircuits, AllStark, Node, StarkConfig};
Expand Down Expand Up @@ -428,6 +428,10 @@ fn test_log_with_aggreg() -> anyhow::Result<()> {
beacon_roots_account_nibbles(),
rlp::encode(&beacon_roots_account).to_vec(),
)?;
expected_state_trie_after.insert(
ger_account_nibbles(),
rlp::encode(&GLOBAL_EXIT_ROOT_ACCOUNT).to_vec(),
)?;

// Compute new receipt trie.
let mut receipts_trie = HashedPartialTrie::from(Node::Empty);
Expand Down Expand Up @@ -479,7 +483,7 @@ fn test_log_with_aggreg() -> anyhow::Result<()> {
// Preprocess all circuits.
let all_circuits = AllRecursiveCircuits::<F, C, D>::new(
&all_stark,
&[16..17, 12..15, 14..18, 14..15, 9..10, 12..13, 17..20],
&[16..17, 8..10, 15..17, 14..15, 10..11, 12..13, 17..19],
&config,
);

Expand Down Expand Up @@ -579,6 +583,11 @@ fn test_log_with_aggreg() -> anyhow::Result<()> {
rlp::encode(&to_account_second_after).to_vec(),
)?;

expected_state_trie_after.insert(
ger_account_nibbles(),
rlp::encode(&GLOBAL_EXIT_ROOT_ACCOUNT).to_vec(),
)?;

// Copy without the beacon roots account for the next block.
let mut state_trie_after_block2 = expected_state_trie_after.clone();

Expand Down

0 comments on commit d2cdae0

Please sign in to comment.