summaryrefslogtreecommitdiffstats
path: root/tokio/tests/sync_mutex_owned.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tokio/tests/sync_mutex_owned.rs')
-rw-r--r--tokio/tests/sync_mutex_owned.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/tokio/tests/sync_mutex_owned.rs b/tokio/tests/sync_mutex_owned.rs
index 394a6708..0f1399c4 100644
--- a/tokio/tests/sync_mutex_owned.rs
+++ b/tokio/tests/sync_mutex_owned.rs
@@ -58,10 +58,11 @@ async fn aborted_future_1() {
let m2 = m1.clone();
// Try to lock mutex in a future that is aborted prematurely
timeout(Duration::from_millis(1u64), async move {
- let mut iv = interval(Duration::from_millis(1000));
+ let iv = interval(Duration::from_millis(1000));
+ tokio::pin!(iv);
m2.lock_owned().await;
- iv.tick().await;
- iv.tick().await;
+ iv.as_mut().tick().await;
+ iv.as_mut().tick().await;
})
.await
.unwrap_err();