mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-09 20:11:09 +00:00
Move spawning tasks from thread pools to Service's TaskManager for block importing (#5647)
Co-Authored-By: Pierre Krieger <pierre.krieger1708@gmail.com>
This commit is contained in:
@@ -84,7 +84,10 @@ fn async_import_queue_drops() {
|
||||
// Perform this test multiple times since it exhibits non-deterministic behavior.
|
||||
for _ in 0..100 {
|
||||
let verifier = PassThroughVerifier(true);
|
||||
let queue = BasicQueue::new(verifier, Box::new(substrate_test_runtime_client::new()), None, None);
|
||||
|
||||
let threads_pool = futures::executor::ThreadPool::new().unwrap();
|
||||
let spawner = |future| threads_pool.spawn_ok(future);
|
||||
let queue = BasicQueue::new(verifier, Box::new(substrate_test_runtime_client::new()), None, None, spawner);
|
||||
drop(queue);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user