Skip to content

Commit

Permalink
Update new rust tests for evm simulator changes
Browse files Browse the repository at this point in the history
  • Loading branch information
IAvecilla committed Sep 4, 2024
1 parent 9eea1c0 commit 8e9a05d
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion core/lib/multivm/src/versions/vm_fast/tests/block_tip.rs
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ fn execute_test(test_data: L1MessengerTestData) -> TestStatistics {
for (i, data) in txs_data.into_iter().enumerate() {
let tx = account.get_l2_tx_for_execute(
Execute {
contract_address: CONTRACT_FORCE_DEPLOYER_ADDRESS,
contract_address: Some(CONTRACT_FORCE_DEPLOYER_ADDRESS),
calldata: data,
value: U256::zero(),
factory_deps: vec![],
Expand Down
2 changes: 1 addition & 1 deletion core/lib/multivm/src/versions/vm_fast/tests/circuits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ fn test_circuits() {
let account = &mut vm.rich_accounts[0];
let tx = account.get_l2_tx_for_execute(
Execute {
contract_address: Address::random(),
contract_address: Some(Address::random()),
calldata: Vec::new(),
value: U256::from(1u8),
factory_deps: vec![],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ fn get_used_contracts_with_out_of_gas_far_call() {
let increment = proxy_counter_abi.function("increment").unwrap();
let increment_tx = account.get_l2_tx_for_execute(
Execute {
contract_address: data.proxy_counter_address,
contract_address: Some(data.proxy_counter_address),
calldata: increment
.encode_input(&[Token::Uint(1.into()), Token::Uint(u64::MAX.into())])
.unwrap(),
Expand Down
6 changes: 3 additions & 3 deletions core/lib/multivm/src/versions/vm_fast/tests/precompiles.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ fn test_keccak() {
let account = &mut vm.rich_accounts[0];
let tx = account.get_l2_tx_for_execute(
Execute {
contract_address: address,
contract_address: Some(address),
calldata: hex::decode(keccak1000_calldata).unwrap(),
value: 0.into(),
factory_deps: vec![],
Expand Down Expand Up @@ -65,7 +65,7 @@ fn test_sha256() {
let account = &mut vm.rich_accounts[0];
let tx = account.get_l2_tx_for_execute(
Execute {
contract_address: address,
contract_address: Some(address),
calldata: hex::decode(sha1000_calldata).unwrap(),
value: 0.into(),
factory_deps: vec![],
Expand Down Expand Up @@ -95,7 +95,7 @@ fn test_ecrecover() {
let account = &mut vm.rich_accounts[0];
let tx = account.get_l2_tx_for_execute(
Execute {
contract_address: account.address,
contract_address: Some(account.address),
calldata: vec![],
value: 0.into(),
factory_deps: vec![],
Expand Down
1 change: 1 addition & 0 deletions core/node/api_server/src/execution_sandbox/testonly.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ impl MockOneshotExecutor {
logs: Default::default(),
statistics: Default::default(),
refunds: Default::default(),
new_known_factory_deps: Default::default(),
}
},
)
Expand Down
1 change: 1 addition & 0 deletions core/node/api_server/src/web3/tests/vm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -336,6 +336,7 @@ impl HttpTest for SendTransactionWithDetailedOutputTest {
logs: vm_execution_logs.clone(),
statistics: Default::default(),
refunds: Default::default(),
new_known_factory_deps: Default::default(),
}
});
tx_executor
Expand Down
1 change: 1 addition & 0 deletions core/node/state_keeper/src/tests/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ pub(super) fn create_execution_result(
circuit_statistic: Default::default(),
},
refunds: Refunds::default(),
new_known_factory_deps: Default::default(),
}
}

Expand Down

0 comments on commit 8e9a05d

Please sign in to comment.