Skip to content

Commit 99b306a

Browse files
committed
Silence the global executor errors
1 parent 5bad816 commit 99b306a

File tree

2 files changed

+16
-13
lines changed

2 files changed

+16
-13
lines changed

crates/metering/src/tests/chain_state.rs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@ use alloy_provider::Provider;
55
use alloy_rpc_types_eth::TransactionInput;
66
use alloy_sol_types::{SolCall, sol};
77
use base_reth_flashblocks_rpc::rpc::FlashblocksAPI;
8-
use base_reth_test_utils::{flashblocks_harness::FlashblocksHarness, node::BASE_CHAIN_ID};
8+
use base_reth_test_utils::{
9+
flashblocks_harness::FlashblocksHarness, node::BASE_CHAIN_ID, tracing::init_silenced_tracing,
10+
};
911
use eyre::{Result, eyre};
1012
use hex_literal::hex;
1113
use op_alloy_consensus::OpTxEnvelope;
@@ -21,7 +23,7 @@ use crate::rpc::{MeteringApiImpl, MeteringApiServer};
2123

2224
#[tokio::test]
2325
async fn meter_bundle_simulation_reflects_pending_state() -> Result<()> {
24-
reth_tracing::init_test_tracing();
26+
init_silenced_tracing();
2527
let harness = FlashblocksHarness::new().await?;
2628

2729
let provider = harness.provider();
@@ -133,7 +135,7 @@ async fn meter_bundle_simulation_reflects_pending_state() -> Result<()> {
133135

134136
#[tokio::test]
135137
async fn meter_bundle_errors_when_beacon_root_missing() -> Result<()> {
136-
reth_tracing::init_test_tracing();
138+
init_silenced_tracing();
137139
let harness = FlashblocksHarness::new().await?;
138140

139141
let provider = harness.provider();
@@ -265,7 +267,7 @@ fn envelope_from_signed(tx: TransactionSigned) -> (OpTxEnvelope, Bytes) {
265267

266268
#[tokio::test]
267269
async fn meter_bundle_reads_canonical_storage_without_mutation() -> Result<()> {
268-
reth_tracing::init_test_tracing();
270+
init_silenced_tracing();
269271
let harness = FlashblocksHarness::new().await?;
270272
let alice = &harness.accounts().alice;
271273
let alice_secret = secret_from_hex(alice.private_key);

crates/metering/src/tests/rpc.rs

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ use alloy_provider::Provider;
44
use base_reth_test_utils::{
55
flashblocks_harness::FlashblocksHarness,
66
node::{BASE_CHAIN_ID, LocalFlashblocksState, LocalNodeProvider},
7+
tracing::init_silenced_tracing,
78
};
89
use eyre::{Result, eyre};
910
use op_alloy_consensus::OpTxEnvelope;
@@ -67,7 +68,7 @@ fn create_bundle(txs: Vec<Bytes>, block_number: u64, min_timestamp: Option<u64>)
6768

6869
#[tokio::test]
6970
async fn test_meter_bundle_empty() -> Result<()> {
70-
reth_tracing::init_test_tracing();
71+
init_silenced_tracing();
7172
let ctx = RpcTestContext::new().await?;
7273

7374
let bundle = create_bundle(vec![], 0, None);
@@ -85,7 +86,7 @@ async fn test_meter_bundle_empty() -> Result<()> {
8586

8687
#[tokio::test]
8788
async fn test_meter_bundle_single_transaction() -> Result<()> {
88-
reth_tracing::init_test_tracing();
89+
init_silenced_tracing();
8990
let ctx = RpcTestContext::new().await?;
9091

9192
let sender_account = &ctx.accounts().alice;
@@ -126,7 +127,7 @@ async fn test_meter_bundle_single_transaction() -> Result<()> {
126127

127128
#[tokio::test]
128129
async fn test_meter_bundle_multiple_transactions() -> Result<()> {
129-
reth_tracing::init_test_tracing();
130+
init_silenced_tracing();
130131
let ctx = RpcTestContext::new().await?;
131132

132133
let secret1 = secret_from_hex(ctx.accounts().alice.private_key);
@@ -181,7 +182,7 @@ async fn test_meter_bundle_multiple_transactions() -> Result<()> {
181182

182183
#[tokio::test]
183184
async fn test_meter_bundle_invalid_transaction() -> Result<()> {
184-
reth_tracing::init_test_tracing();
185+
init_silenced_tracing();
185186
let ctx = RpcTestContext::new().await?;
186187

187188
let bundle = create_bundle(vec![Bytes::from_static(b"\xde\xad\xbe\xef")], 0, None);
@@ -193,7 +194,7 @@ async fn test_meter_bundle_invalid_transaction() -> Result<()> {
193194

194195
#[tokio::test]
195196
async fn test_meter_bundle_uses_latest_block() -> Result<()> {
196-
reth_tracing::init_test_tracing();
197+
init_silenced_tracing();
197198
let ctx = RpcTestContext::new().await?;
198199

199200
ctx.harness().advance_chain(2).await?;
@@ -209,7 +210,7 @@ async fn test_meter_bundle_uses_latest_block() -> Result<()> {
209210

210211
#[tokio::test]
211212
async fn test_meter_bundle_ignores_bundle_block_number() -> Result<()> {
212-
reth_tracing::init_test_tracing();
213+
init_silenced_tracing();
213214
let ctx = RpcTestContext::new().await?;
214215

215216
let bundle1 = create_bundle(vec![], 0, None);
@@ -227,7 +228,7 @@ async fn test_meter_bundle_ignores_bundle_block_number() -> Result<()> {
227228

228229
#[tokio::test]
229230
async fn test_meter_bundle_custom_timestamp() -> Result<()> {
230-
reth_tracing::init_test_tracing();
231+
init_silenced_tracing();
231232
let ctx = RpcTestContext::new().await?;
232233

233234
let custom_timestamp = 1_234_567_890;
@@ -242,7 +243,7 @@ async fn test_meter_bundle_custom_timestamp() -> Result<()> {
242243

243244
#[tokio::test]
244245
async fn test_meter_bundle_arbitrary_block_number() -> Result<()> {
245-
reth_tracing::init_test_tracing();
246+
init_silenced_tracing();
246247
let ctx = RpcTestContext::new().await?;
247248

248249
let bundle = create_bundle(vec![], 999_999, None);
@@ -256,7 +257,7 @@ async fn test_meter_bundle_arbitrary_block_number() -> Result<()> {
256257

257258
#[tokio::test]
258259
async fn test_meter_bundle_gas_calculations() -> Result<()> {
259-
reth_tracing::init_test_tracing();
260+
init_silenced_tracing();
260261
let ctx = RpcTestContext::new().await?;
261262

262263
let secret1 = secret_from_hex(ctx.accounts().alice.private_key);

0 commit comments

Comments
 (0)