LR-BEHAV-UNDO: each rename-provenance fixture gets its own folder (#874's tests shared one and failed when run in parallel)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BKWB9TCnvzJHV6xMLAj2J4
This commit is contained in:
Claude
2026-10-11 13:08:37 +00:00
parent 4ff1d9761d
commit 7fe8f8dbd1
@@ -64,7 +64,10 @@ struct Partial {
target: PathBuf,
}
fn partial(style: SidecarNaming, upper_stem: bool, upper_full: bool, shared: bool) -> Partial {
let dir = crate::tests_xmp::temp_dir("sidecar-provenance");
// one folder per fixture: tests run in parallel, and each removes its folder at the end
static NEXT: std::sync::atomic::AtomicUsize = std::sync::atomic::AtomicUsize::new(0);
let n = NEXT.fetch_add(1, std::sync::atomic::Ordering::Relaxed);
let dir = crate::tests_xmp::temp_dir(&format!("sidecar-provenance-{n}"));
let a = dir.join("a.jpg");
let b = dir.join("Trip.jpg");
std::fs::write(&a, b"tiny physical photo; rename does not decode").unwrap();