Skip to content

LightCraft: An open-source non-destructive photo editor written by scratch in pure Rust

tests_import: without a library the imported profile keeps no file path at all

Marco Arnulfobcef909d40f7
diff --git a/crates/engine/src/tests_import.rs b/crates/engine/src/tests_import.rs
index 1ac68c7bd..7d1984746 100644
--- a/crates/engine/src/tests_import.rs
+++ b/crates/engine/src/tests_import.rs
@@ -630,7 +630,7 @@ fn cube_import_without_a_library_leaves_no_temp_copy() {
let id = r["imported"][0]["id"].as_str().unwrap().to_string();
assert!(lightcraft_pipeline::lut::get(&id).is_some(), "usable in this session");
let file = s.lut_profiles.iter().find(|p| p.id == id).unwrap().file.clone();
- assert!(file.is_empty() || Path::new(&file).starts_with(&src), "no copy written: {file}");
+ assert!(file.is_empty(), "no file kept without a library: {file}");
drop(s);
assert!(!leak.exists(), "{} left behind", leak.display());
lightcraft_pipeline::lut::unregister(&id);