ci: fix warning in windows build

This commit is contained in:
andy.boot
2024-07-17 19:19:54 +01:00
parent 1ab0b2f531
commit 00a7c410a0
+2 -1
View File
@@ -2,7 +2,7 @@ use assert_cmd::Command;
use std::ffi::OsStr; use std::ffi::OsStr;
use std::process::Output; use std::process::Output;
use std::sync::Once; use std::sync::Once;
use std::{fs, io, str}; use std::{io, str};
static INIT: Once = Once::new(); static INIT: Once = Once::new();
static UNREADABLE_DIR_PATH: &str = "/tmp/unreadable_dir"; static UNREADABLE_DIR_PATH: &str = "/tmp/unreadable_dir";
@@ -38,6 +38,7 @@ fn copy_test_data(dir: &str) {
fn create_unreadable_directory() -> io::Result<()> { fn create_unreadable_directory() -> io::Result<()> {
#[cfg(unix)] #[cfg(unix)]
{ {
use std::fs;
use std::fs::Permissions; use std::fs::Permissions;
use std::os::unix::fs::PermissionsExt; use std::os::unix::fs::PermissionsExt;
fs::create_dir_all(UNREADABLE_DIR_PATH)?; fs::create_dir_all(UNREADABLE_DIR_PATH)?;