From dbcf8e24da7c7ba7a198b72bdaefe5e0398f60ab Mon Sep 17 00:00:00 2001 From: Oliver Nordbjerg Date: Sat, 19 Oct 2024 14:03:11 +0200 Subject: [PATCH] test: update 7002 tests --- crates/ethereum/evm/src/execute.rs | 8 ++++---- crates/ethereum/evm/src/strategy.rs | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/crates/ethereum/evm/src/execute.rs b/crates/ethereum/evm/src/execute.rs index 022214df6f36..428458fcd04a 100644 --- a/crates/ethereum/evm/src/execute.rs +++ b/crates/ethereum/evm/src/execute.rs @@ -511,7 +511,7 @@ mod tests { database::StateProviderDatabase, test_utils::StateProviderTest, TransitionState, }; use reth_testing_utils::generators::{self, sign_tx_with_key_pair}; - use revm_primitives::{bytes, BLOCKHASH_SERVE_WINDOW}; + use revm_primitives::BLOCKHASH_SERVE_WINDOW; use secp256k1::{Keypair, Secp256k1}; use std::collections::HashMap; @@ -1297,9 +1297,9 @@ mod tests { let receipt = receipts.first().unwrap(); assert!(receipt.success); - let request = requests.first().unwrap(); - // TODO: must be empty? @onbjerg - assert_eq!(request, &bytes!("00")); // todo: placeholder + assert!(requests[0].is_empty(), "there should be no deposits"); + assert!(!requests[1].is_empty(), "there should be a withdrawal"); + assert!(requests[2].is_empty(), "there should be no consolidations"); } #[test] diff --git a/crates/ethereum/evm/src/strategy.rs b/crates/ethereum/evm/src/strategy.rs index 55f7721ddf68..714f673c8582 100644 --- a/crates/ethereum/evm/src/strategy.rs +++ b/crates/ethereum/evm/src/strategy.rs @@ -273,7 +273,7 @@ mod tests { eip7002::{WITHDRAWAL_REQUEST_PREDEPLOY_ADDRESS, WITHDRAWAL_REQUEST_PREDEPLOY_CODE}, eip7685::EMPTY_REQUESTS_HASH, }; - use alloy_primitives::{b256, bytes, fixed_bytes, keccak256, Bytes, TxKind, B256}; + use alloy_primitives::{b256, fixed_bytes, keccak256, Bytes, TxKind, B256}; use reth_chainspec::{ChainSpecBuilder, ForkCondition}; use reth_evm::execute::{ BasicBlockExecutorProvider, BatchExecutor, BlockExecutorProvider, Executor, @@ -1085,9 +1085,9 @@ mod tests { let receipt = receipts.first().unwrap(); assert!(receipt.success); - let request = requests.first().unwrap(); - // TODO: must be empty? @onbjerg - assert_eq!(request, &bytes!("00")); // todo: placeholder + assert!(requests[0].is_empty(), "there should be no deposits"); + assert!(!requests[1].is_empty(), "there should be a withdrawal"); + assert!(requests[2].is_empty(), "there should be no consolidations"); } #[test]