ui-contract: the icon-fill trial's white tint is marked; icon-trial-fixed-tint covers 4

This commit is contained in:
bflatastic
2026-11-22 21:01:10 +07:00
parent b950fb234a
commit 83f452d669
2 changed files with 3 additions and 2 deletions
@@ -213,6 +213,7 @@ fn an_icon_with_a_fill_keeps_its_colour_under_the_tint() {
register_app_icons(&FILLED_SET);
let [r, g, b, a] = FILL_COLOR;
let fill = Color32::from_rgba_unmultiplied(r, g, b, a);
// design: allow[raw-colour/const](white is the tint that leaves colours unchanged: the fill keeps its colour under it too)
for tint in [Color32::from_rgb(10, 200, 30), Color32::WHITE] {
assert_eq!(painted(FILLED_NAME, tint), [fill, tint], "the fill keeps its colour and the icon takes the tint");
}
@@ -5,8 +5,8 @@ name = "icon-trial-fixed-tint"
kind = "marker"
rule = "raw-colour/const"
path = "crates/ui-contract/src/testing/icon_trials.rs"
reason = "A fixed layer keeps the colours it is drawn in: the trial expects the white tint that leaves them unchanged."
count = 3
reason = "A fixed layer keeps the colours it is drawn in: the trials expect the white tint that leaves them unchanged, and an icon's fill keeps its colour under it."
count = 4
[[exception]]
name = "face-runs-text-size"