From f74169d4af0d71de9f7dc40e37de8ea68ed47882 Mon Sep 17 00:00:00 2001 From: RunDevelopment Date: Tue, 3 Mar 2026 14:11:24 +0100 Subject: [PATCH 1/2] Fix libtiffpic test for Windows --- tests/decode_libtiffpic.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/decode_libtiffpic.rs b/tests/decode_libtiffpic.rs index 0ab0dca..9cc6e96 100644 --- a/tests/decode_libtiffpic.rs +++ b/tests/decode_libtiffpic.rs @@ -115,9 +115,10 @@ fn main() { let Some(path) = entry.path().to_str() else { continue; }; + let path = path.replace('\\', "/"); // always use UNIX path separators // Mark this path as consumed in either case by removing it. - let Some(should_decode) = candidates.remove(path) else { + let Some(should_decode) = candidates.remove(path.as_str()) else { panic!("File {} not in reference list", path); }; From bbb5e5a41b10a2fa73c5a8923b080d53cb3a8905 Mon Sep 17 00:00:00 2001 From: RunDevelopment Date: Tue, 3 Mar 2026 14:13:00 +0100 Subject: [PATCH 2/2] Use std::path::MAIN_SEPARATOR --- tests/decode_libtiffpic.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/decode_libtiffpic.rs b/tests/decode_libtiffpic.rs index 9cc6e96..09e08d7 100644 --- a/tests/decode_libtiffpic.rs +++ b/tests/decode_libtiffpic.rs @@ -115,7 +115,7 @@ fn main() { let Some(path) = entry.path().to_str() else { continue; }; - let path = path.replace('\\', "/"); // always use UNIX path separators + let path = path.replace(std::path::MAIN_SEPARATOR, "/"); // always use UNIX path separators // Mark this path as consumed in either case by removing it. let Some(should_decode) = candidates.remove(path.as_str()) else {