LRC-LIB-LIBFOLDERS: the sidebar rename test builds its folder ids with forward slashes on Windows

The folder tree writes paths with forward slashes and its widget ids
carry them; the test put the temp folder in the id with backslashes.
Found running cargo xtask ci on Windows.
This commit is contained in:
radialmonster 2026-10-08 16:22:59 -04:00
parent 48cd9c5e3a
commit 1fa3af8740
1 changed files with 2 additions and 1 deletions

View File

@ -377,7 +377,8 @@ fn a_renamed_folder_keeps_its_place_in_the_tree() {
let _cleanup = Cleanup(base.clone());
std::fs::create_dir_all(base.join("pics/trip")).unwrap();
std::fs::create_dir_all(base.join("pics/home")).unwrap();
let b = base.to_string_lossy().to_string();
// the folder tree writes paths with forward slashes, and its widget ids carry them
let b = base.to_string_lossy().replace('\\', "/");
let mut h = folders_app(&[&format!("{b}/pics/trip/a.jpg"), &format!("{b}/pics/home/b.jpg")]);
h.app.session.source = lightcraft_engine::LibrarySource::LibraryFolder;
h.app.session.library_folder = Some(format!("{b}/pics/trip"));