Function futures_test::task::panic_spawner_mut
source · [−]pub fn panic_spawner_mut() -> &'static mut PanicSpawner
Expand description
Get a reference to a singleton instance of PanicSpawner
.
Examples
ⓘ
use futures::task::SpawnExt;
use futures_test::task::panic_spawner_mut;
let spawner = panic_spawner_mut();
spawner.spawn(async { })?; // Will panic