From 472560b30936259fe50f8df67b9ad57ea8ef7a6d Mon Sep 17 00:00:00 2001 From: FredApps <153173854+FredApps@users.noreply.github.com> Date: Fri, 6 Nov 2026 02:36:08 +0100 Subject: [PATCH] Tests: clipping warnings crush the shadows with Blacks (#3839) Main fails this test: Exposure -5 alone no longer leaves a channel at 0 in the demo photo. Co-authored-by: Claude Opus 5.5 --- crates/ui-egui/src/tests/alt_preview.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/crates/ui-egui/src/tests/alt_preview.rs b/crates/ui-egui/src/tests/alt_preview.rs index 5997b41b43..96a9d60e6d 100644 --- a/crates/ui-egui/src/tests/alt_preview.rs +++ b/crates/ui-egui/src/tests/alt_preview.rs @@ -97,6 +97,10 @@ fn j_paints_clipped_highlights_red_and_clipped_shadows_blue() { assert!(h.app.ui.show_clipping); assert!(share_of(&h, red) > 0.5, "blown highlights shown in red: {}", share_of(&h, red)); set(&mut h, -5.0); + // the demo photo's shadows don't reach black on Exposure alone: Blacks crushes them + let r = h.request("engine.execute", json!({"command": "develop.set", "params": {"control": "light.blacks", "value": -100.0}}), T); + assert_eq!(r["ok"], true, "{r}"); + h.settle(SETTLE); assert!(share_of(&h, blue) > 0.01, "crushed shadows shown in blue: {}", share_of(&h, blue)); assert!(share_of(&h, red) < 0.01, "nothing blown at -5 EV: {}", share_of(&h, red)); }