From 5ebb6796fe2524eefa76e98291363c7b1574dcdb Mon Sep 17 00:00:00 2001 From: dotCooCoo Date: Wed, 4 Nov 2026 02:31:26 -0800 Subject: [PATCH] Tests: skip the Arabic Optical kerning test without craft-fonts optical_pair_after_rtl_separate_mark_uses_base_outline sets Noto Sans Arabic, which is not in assets/fonts. Without CRAFT_FONTS_DIR the font database returns a fallback face, so the test checked that face instead. The test now skips when Noto Sans Arabic is missing, as the Shippori Mincho tests in the same file do. --- crates/text/src/tests/typo.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/crates/text/src/tests/typo.rs b/crates/text/src/tests/typo.rs index 092ed4c09..689e956b3 100644 --- a/crates/text/src/tests/typo.rs +++ b/crates/text/src/tests/typo.rs @@ -172,6 +172,10 @@ fn optical_pair_after_separate_combining_mark_uses_base_outline() { #[test] fn optical_pair_after_rtl_separate_mark_uses_base_outline() { + if db().face("Noto Sans Arabic", "Regular").is_none_or(|f| f.family != "Noto Sans Arabic") { + eprintln!("skipped: built without craft-fonts (set CRAFT_FONTS_DIR to a craft-fonts checkout to run it)"); + return; + } let st = CharStyle { font_family: "Noto Sans Arabic".into(), size: 100.0, optical_kerning: true, ..CharStyle::default() }; let shaped = |text: &str, manual: bool| { let mut style = st.clone();