Skip to content

Commit 87cff67

Browse files
Fix for unit-tests on non-unix systems
1 parent 3ca65e1 commit 87cff67

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

src/main.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
use std::{
33
io,
44
net::{SocketAddr, SocketAddrV4, SocketAddrV6, ToSocketAddrs},
5+
path::PathBuf,
56
time::Duration,
67
};
78

@@ -13,17 +14,16 @@ use iroh::{
1314
};
1415
use iroh_persist::KeyRetriever;
1516
use n0_error::{bail_any, ensure_any, AnyError, Result, StdResultExt};
17+
18+
#[cfg(unix)]
19+
use tokio::net::{UnixListener, UnixStream};
20+
1621
use tokio::{
1722
io::{AsyncRead, AsyncWrite, AsyncWriteExt},
1823
select,
1924
time::timeout,
2025
};
2126
use tokio_util::sync::CancellationToken;
22-
#[cfg(unix)]
23-
use {
24-
std::path::PathBuf,
25-
tokio::net::{UnixListener, UnixStream},
26-
};
2727

2828
const ONLINE_TIMEOUT: Duration = Duration::from_secs(5);
2929

0 commit comments

Comments
 (0)