public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [tests/fonts] rhel9: validate_family: Add FONT_EXCLUDE to skip some bogus fonts
@ 2026-08-13 10:29 Akira TAGOH
0 siblings, 0 replies; only message in thread
From: Akira TAGOH @ 2026-08-13 10:29 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : tests/fonts
Branch : rhel9
Commit : eb5b828e59b2c595c507209ddc7e28693b25ee7e
Author : Akira TAGOH <akira@tagoh.org>
Date : 2024-06-25T18:15:12+09:00
Stats : +15/-1 in 2 file(s)
URL : https://src.fedoraproject.org/tests/fonts/c/eb5b828e59b2c595c507209ddc7e28693b25ee7e?branch=rhel9
Log:
validate_family: Add FONT_EXCLUDE to skip some bogus fonts
---
diff --git a/README.rst b/README.rst
index 785e6cd..80f4fda 100644
--- a/README.rst
+++ b/README.rst
@@ -105,6 +105,9 @@ Available test cases
- PACKAGE
- FONT_FAMILY
+ - FONT_EXCLUDE (optional)
+
+ Set a regexp to skip some bogus fonts.
FAQ
---
diff --git a/tests/validate_family/test.sh b/tests/validate_family/test.sh
index 87f751d..8c389fc 100755
--- a/tests/validate_family/test.sh
+++ b/tests/validate_family/test.sh
@@ -10,6 +10,15 @@ function get_font_path() {
echo -n $ret
}
+function check_exception() {
+ if [ "x$FONT_EXCLUDE" == "x" ]; then
+ echo -n 1
+ else
+ echo $1 | grep -E "$FONT_EXCLUDE" 2>&1 > /dev/null
+ echo -n $?
+ fi
+}
+
rlJournalStart
rlPhaseStartSetup
rlRun "tmp=\$(mktemp -d)" 0 "Create tmp directory"
@@ -21,9 +30,11 @@ rlJournalStart
for p in $(get_font_path); do
for f in $(find $p -regex '.*/*\.\(t1\)?\(ttf\)?\(otf\)?\(ttc\)?\(otc\)?\(pcf.*\)?\(pfa\)?'); do
set -f
- if test -f $f; then
+ if [ $(check_exception $f) -ne 0 -a -f $f ]; then
rlRun "fc-scan -f \"%{family[0]}\\n\" $f | tee output" 0 "Querying family name"
rlAssertGrep "$FONT_FAMILY" "output"
+ else
+ rlLogInfo "Skipping $f"
fi
done
done
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-08-13 10:29 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-13 10:29 [tests/fonts] rhel9: validate_family: Add FONT_EXCLUDE to skip some bogus fonts Akira TAGOH
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox