Skip to content

DesignCraft: An open-source page and layout design editor written by scratch in pure Rust

Preferences test: the recent items count is 20

moppeeercb9d23dd521c
diff --git a/crates/ui-egui/src/dialogs.rs b/crates/ui-egui/src/dialogs.rs
index bed4cdf04..a0ce16e47 100644
--- a/crates/ui-egui/src/dialogs.rs
+++ b/crates/ui-egui/src/dialogs.rs
@@ -7435,7 +7435,7 @@ mod tests {
let labels = dialog_frame(&mut app, &ctx, screen, vec![]);
visible_label(&labels, screen, "Number of Recent Items to Display:");
let count = app.ui.dialog.as_ref().unwrap().n("recentFilesMax").unwrap();
- assert_eq!(count.fract(), 0.0);
+ assert_eq!(count, 20.0, "InDesign's default");
visible_label(&labels, screen, &format!("{count}"));
assert!(!labels.iter().any(|(t, _, _)| t.trim() == format!("{count:.1}")), "no decimal shown");
}