From 17921714c396b9019ad4272d6ba153af4860f04c Mon Sep 17 00:00:00 2001 From: yaziciahmet Date: Fri, 20 Dec 2024 23:36:00 +0100 Subject: [PATCH] Lint --- crates/evm/src/tests/call_tests.rs | 9 ++++++--- crates/evm/src/tests/fork_tests.rs | 4 +++- crates/evm/src/tests/hooks_tests.rs | 2 +- crates/evm/src/tests/utils.rs | 5 ++++- 4 files changed, 14 insertions(+), 6 deletions(-) diff --git a/crates/evm/src/tests/call_tests.rs b/crates/evm/src/tests/call_tests.rs index ff08f6967..650814b3a 100644 --- a/crates/evm/src/tests/call_tests.rs +++ b/crates/evm/src/tests/call_tests.rs @@ -28,7 +28,10 @@ use crate::smart_contracts::{ }; use crate::tests::test_signer::TestSigner; use crate::tests::utils::{ - config_push_contracts, create_contract_message, create_contract_message_with_fee, create_contract_message_with_fee_and_gas_limit, create_contract_transaction, get_evm, get_evm_config, get_evm_config_starting_base_fee, get_evm_with_spec, publish_event_message, set_arg_message + config_push_contracts, create_contract_message, create_contract_message_with_fee, + create_contract_message_with_fee_and_gas_limit, create_contract_transaction, get_evm, + get_evm_config, get_evm_config_starting_base_fee, get_evm_with_spec, publish_event_message, + set_arg_message, }; use crate::tests::DEFAULT_CHAIN_ID; use crate::{ @@ -1246,7 +1249,7 @@ fn test_l1_fee_success() { }, gas_used: 50751, log_index_start: 0, - l1_diff_size: 53, + l1_diff_size: 53, }, Receipt { receipt: reth_primitives::Receipt { @@ -1319,7 +1322,7 @@ fn test_l1_fee_success() { }, gas_used: 114235, log_index_start: 1, - l1_diff_size: 52 + l1_diff_size: 52, } ] ) diff --git a/crates/evm/src/tests/fork_tests.rs b/crates/evm/src/tests/fork_tests.rs index 818596de7..0f79562cf 100644 --- a/crates/evm/src/tests/fork_tests.rs +++ b/crates/evm/src/tests/fork_tests.rs @@ -17,7 +17,9 @@ use crate::smart_contracts::{ SelfdestructingConstructorContract, SimpleStorageContract, TransientStorageContract, }; use crate::tests::test_signer::TestSigner; -use crate::tests::utils::{create_contract_message, get_evm, get_evm_config, get_evm_with_spec, set_arg_message}; +use crate::tests::utils::{ + create_contract_message, get_evm, get_evm_config, get_evm_with_spec, set_arg_message, +}; use crate::RlpEvmTransaction; type C = DefaultContext; diff --git a/crates/evm/src/tests/hooks_tests.rs b/crates/evm/src/tests/hooks_tests.rs index 0ac382f9b..d895ce622 100644 --- a/crates/evm/src/tests/hooks_tests.rs +++ b/crates/evm/src/tests/hooks_tests.rs @@ -96,7 +96,7 @@ fn end_soft_confirmation_hook_sets_head() { .get(&mut working_set.accessory_state()) .unwrap(); - assert_eq!(head, pending_head.into()); + assert_eq!(head, pending_head); assert_eq!( head, Block { diff --git a/crates/evm/src/tests/utils.rs b/crates/evm/src/tests/utils.rs index 28924ba42..1ba486428 100644 --- a/crates/evm/src/tests/utils.rs +++ b/crates/evm/src/tests/utils.rs @@ -57,7 +57,10 @@ pub(crate) fn get_evm(config: &EvmConfig) -> (Evm, WorkingSet<::St get_evm_with_spec(config, SovSpecId::Fork1) } -pub(crate) fn get_evm_with_spec(config: &EvmConfig, spec_id: SovSpecId) -> (Evm, WorkingSet<::Storage>) { +pub(crate) fn get_evm_with_spec( + config: &EvmConfig, + spec_id: SovSpecId, +) -> (Evm, WorkingSet<::Storage>) { let tmpdir = tempfile::tempdir().unwrap(); let storage = new_orphan_storage(tmpdir.path()).unwrap(); let mut working_set = WorkingSet::new(storage.clone());