Skip to content

Commit

Permalink
fix: spawn network manager on test exex ctx (#11907)
Browse files Browse the repository at this point in the history
  • Loading branch information
loocapro authored Oct 22, 2024
1 parent e52f647 commit 1342747
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions crates/exex/test-utils/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -268,15 +268,16 @@ pub async fn test_exex_context_with_chain_spec(
let network_manager = NetworkManager::new(
NetworkConfigBuilder::new(SecretKey::new(&mut rand::thread_rng()))
.with_unused_discovery_port()
.with_unused_listener_port()
.build(provider_factory.clone()),
)
.await?;
let network = network_manager.handle().clone();

let (_, payload_builder) = NoopPayloadBuilderService::<EthEngineTypes>::new();

let tasks = TaskManager::current();
let task_executor = tasks.executor();
tasks.executor().spawn(network_manager);

let (_, payload_builder) = NoopPayloadBuilderService::<EthEngineTypes>::new();

let components = NodeAdapter::<FullNodeTypesAdapter<NodeTypesWithDBAdapter<TestNode, _>, _>, _> {
components: Components {
Expand Down

0 comments on commit 1342747

Please sign in to comment.