diff --git a/src/sftp/client.rs b/src/sftp/client.rs index 9f9acfe..38e7f07 100644 --- a/src/sftp/client.rs +++ b/src/sftp/client.rs @@ -94,7 +94,8 @@ impl SftpClient { fsync, }) } - #[cfg(test)] + /// Only the Unix tests have a local `sftp-server` to talk to. + #[cfg(all(test, unix))] pub(super) async fn local_test_server( directory: &std::path::Path, ) -> Result<(Self, tokio::process::Child)> { diff --git a/src/sftp/tests.rs b/src/sftp/tests.rs index 130b905..ea1e95a 100644 --- a/src/sftp/tests.rs +++ b/src/sftp/tests.rs @@ -1590,6 +1590,7 @@ fn an_scp_upload_takes_the_destination_name_and_keeps_the_execute_bits() { }); } +#[cfg(unix)] async fn batch_to( source: &Path, destination: &str,