Skip to content

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

LR-IMP-PREVIEW-READ: UI thumbnail tests stub the reduced loader too

Matthew James Sivaka3c1d6c0f556
diff --git a/crates/ui-egui/src/render.rs b/crates/ui-egui/src/render.rs
index 64ab067b7..d04a764c2 100644
--- a/crates/ui-egui/src/render.rs
+++ b/crates/ui-egui/src/render.rs
@@ -1128,6 +1128,8 @@ mod thumbnail_tests {
image.data.fill([0.3, 0.2, 0.1]);
Ok((image, Default::default()))
}));
+ // (`with_fs` sets the file system's thumbnail loader, which wins over `file_loader`: thumbnails use the stub too)
+ s.media.reduced_loader = None;
s.catalog.apply(Op::AddPhoto { photo: Box::new(photo) }).unwrap();
let mut app = crate::LightcraftApp::new(s, crate::Services::default());
app.renderer.keep_pixels = true;