pub fn panic_context() -> Context<'static>
Expand description

Create a new Context where the waker will panic if used.

Examples

use futures_test::task::panic_context;

let cx = panic_context();
cx.waker().wake_by_ref(); // Will panic