Skip to content

Commit 1ba054a

Browse files
committed
Actually delay by 1 second
1 parent a7f0488 commit 1ba054a

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

postgres-tokio/src/test.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use futures::{Future, IntoFuture};
1+
use futures::{Future, Stream};
22
use futures_state_stream::StateStream;
33
use std::error::Error as StdError;
44
use std::time::Duration;
@@ -343,9 +343,10 @@ fn cancel() {
343343
let c = c.unwrap();
344344
let cancel_data = c.cancel_data();
345345
let cancel = Interval::new(Duration::from_secs(1), &handle)
346+
.unwrap()
346347
.into_future()
347348
.then(move |r| {
348-
r.unwrap();
349+
assert!(r.is_ok());
349350
cancel_query("postgres://postgres@localhost",
350351
TlsMode::None,
351352
cancel_data,

0 commit comments

Comments
 (0)