mirror of
https://github.com/rust-lang/futures-rs.git
synced 2026-01-25 03:26:14 +00:00
Tweak imports in tests
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
use futures::executor::block_on;
|
||||
use futures::future::Future;
|
||||
use futures::future::{self, Future};
|
||||
use std::task::Poll;
|
||||
|
||||
/// This tests verifies (through miri) that self-referencing
|
||||
@@ -21,7 +21,7 @@ async fn trouble() {
|
||||
|
||||
fn yield_now() -> impl Future<Output = ()> {
|
||||
let mut yielded = false;
|
||||
std::future::poll_fn(move |cx| {
|
||||
future::poll_fn(move |cx| {
|
||||
if core::mem::replace(&mut yielded, true) {
|
||||
Poll::Ready(())
|
||||
} else {
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
use futures::executor::block_on;
|
||||
use futures::future::{err, ok, try_join_all, Future, TryJoinAll};
|
||||
use futures::pin_mut;
|
||||
use futures_util::future::{err, ok, try_join_all, TryJoinAll};
|
||||
use std::fmt::Debug;
|
||||
use std::future::Future;
|
||||
|
||||
#[track_caller]
|
||||
fn assert_done<T>(actual_fut: impl Future<Output = T>, expected: T)
|
||||
|
||||
Reference in New Issue
Block a user