From be5836e14dfc5587122dd4cbcc8ff6a0a79e151e Mon Sep 17 00:00:00 2001 From: Chris Hennick <4961925+Pr0methean@users.noreply.github.com> Date: Fri, 10 May 2024 15:01:11 -0700 Subject: [PATCH] test: Fix unused imports by moving them inside the cfg-gated test --- tests/repro_old423.rs | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/tests/repro_old423.rs b/tests/repro_old423.rs index 613ebd53..05e74cf0 100644 --- a/tests/repro_old423.rs +++ b/tests/repro_old423.rs @@ -1,13 +1,12 @@ -use std::env::temp_dir; -use std::io; -use zip::result::ZipResult; -use zip::ZipArchive; - #[cfg(all(unix, feature = "_deflate-any"))] #[test] -fn repro_old423() -> ZipResult<()> { +fn repro_old423() -> zip::result::ZipResult<()> { + use std::env::temp_dir; + use std::io; + use zip::ZipArchive; + let mut v = Vec::new(); v.extend_from_slice(include_bytes!("data/lin-ub_iwd-v11.zip")); let mut archive = ZipArchive::new(io::Cursor::new(v)).expect("couldn't open test zip file"); archive.extract(temp_dir()) -} \ No newline at end of file +}