mirror of
https://github.com/harfbuzz/harfbuzz.git
synced 2025-04-05 05:25:05 +00:00
[test/shape] Respect @shapers directive
Some checks failed
arm / arm-none-eabi (push) Waiting to run
configs-ci / build (push) Waiting to run
fontations / build (push) Waiting to run
linux-ci / build (push) Waiting to run
macos-ci / build (push) Waiting to run
msvc / msvc-2019-amd64 (push) Waiting to run
msvc / msvc-2019-x86 (push) Waiting to run
msys2 / MINGW32 (push) Waiting to run
msys2 / MINGW64 (push) Waiting to run
msys2 / CLANG64 (push) Waiting to run
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1s
Some checks failed
arm / arm-none-eabi (push) Waiting to run
configs-ci / build (push) Waiting to run
fontations / build (push) Waiting to run
linux-ci / build (push) Waiting to run
macos-ci / build (push) Waiting to run
msvc / msvc-2019-amd64 (push) Waiting to run
msvc / msvc-2019-x86 (push) Waiting to run
msys2 / MINGW32 (push) Waiting to run
msys2 / MINGW64 (push) Waiting to run
msys2 / CLANG64 (push) Waiting to run
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1s
This commit is contained in:
parent
bb3a55a61a
commit
46a30fe390
3 changed files with 53 additions and 50 deletions
|
@ -1 +1,2 @@
|
|||
../fonts/872d2955d326bd6676a06f66b8238ebbaabc212f.ttf;--shaper=coretext;U+0628,U+0628,U+0628;[uni0628.fina=2+883|uni0628.medi_High=1+244|uni0628.init_High=0+233]
|
||||
@shapers=ot,coretext
|
||||
../fonts/872d2955d326bd6676a06f66b8238ebbaabc212f.ttf;;U+0628,U+0628,U+0628;[uni0628.fina=2+883|uni0628.medi_High=1+244|uni0628.init_High=0+233]
|
||||
|
|
|
@ -1,11 +1,12 @@
|
|||
@font-funcs-=directwrite
|
||||
../fonts/872d2955d326bd6676a06f66b8238ebbaabc212f.ttf;--shaper=directwrite;U+0628,U+0628,U+0628;[uni0628.fina=2+883|uni0628.medi_High=1+244|uni0628.init_High=0+233]
|
||||
../fonts/7bbd3175734d5d291e1c15271ec0cbb97b626ebf.ttf;--shaper=directwrite;U+0066,U+0066,U+0069;[f_f_i=0+795]
|
||||
../fonts/7bbd3175734d5d291e1c15271ec0cbb97b626ebf.ttf;--shaper=directwrite --features=-liga;U+0066,U+0066,U+0069;[f=0+300|f=1+300|i=2+263]
|
||||
../fonts/7bbd3175734d5d291e1c15271ec0cbb97b626ebf.ttf;--shaper=directwrite;U+0648,U+0628,U+0627;[alef-ar.fina=2+229|beh-ar.init=1+190|waw-ar=0+483]
|
||||
../fonts/7bbd3175734d5d291e1c15271ec0cbb97b626ebf.ttf;--shaper=directwrite --features=ss01;U+0648,U+0628,U+0627;[alef-ar.fina=2+229|beh-ar.init.LD=1+190|waw-ar=0+400]
|
||||
#../fonts/HBTest-VF.ttf;--shaper=directwrite --variations=TEST=491;U+0041;[A=0+496]
|
||||
#../fonts/HBTest-VF.ttf;--shaper=directwrite --variations=TEST=509;U+0041;[A=0+505]
|
||||
../fonts/ab40c89624a6104e5d0a2308e448a989302f515b.ttf;--shaper=directwrite --variations=wdth=60;U+0020;[space=0+266]
|
||||
../fonts/ab40c89624a6104e5d0a2308e448a989302f515b.ttf;--shaper=directwrite --variations=wdth=402;U+0020;[space=0+639]
|
||||
../fonts/e8691822f6a705e3e9fb48a0405c645b1a036590.ttf;--shaper=directwrite --variations=0001=500;U+002E,U+0065;[period=0+681|e=1+650]
|
||||
@shapers=directwrite
|
||||
../fonts/872d2955d326bd6676a06f66b8238ebbaabc212f.ttf;;U+0628,U+0628,U+0628;[uni0628.fina=2+883|uni0628.medi_High=1+244|uni0628.init_High=0+233]
|
||||
../fonts/7bbd3175734d5d291e1c15271ec0cbb97b626ebf.ttf;;U+0066,U+0066,U+0069;[f_f_i=0+795]
|
||||
../fonts/7bbd3175734d5d291e1c15271ec0cbb97b626ebf.ttf;--features=-liga;U+0066,U+0066,U+0069;[f=0+300|f=1+300|i=2+263]
|
||||
../fonts/7bbd3175734d5d291e1c15271ec0cbb97b626ebf.ttf;;U+0648,U+0628,U+0627;[alef-ar.fina=2+229|beh-ar.init=1+190|waw-ar=0+483]
|
||||
../fonts/7bbd3175734d5d291e1c15271ec0cbb97b626ebf.ttf;--features=ss01;U+0648,U+0628,U+0627;[alef-ar.fina=2+229|beh-ar.init.LD=1+190|waw-ar=0+400]
|
||||
#../fonts/HBTest-VF.ttf;--variations=TEST=491;U+0041;[A=0+496]
|
||||
#../fonts/HBTest-VF.ttf;--variations=TEST=509;U+0041;[A=0+505]
|
||||
../fonts/ab40c89624a6104e5d0a2308e448a989302f515b.ttf;--variations=wdth=60;U+0020;[space=0+266]
|
||||
../fonts/ab40c89624a6104e5d0a2308e448a989302f515b.ttf;--variations=wdth=402;U+0020;[space=0+639]
|
||||
../fonts/e8691822f6a705e3e9fb48a0405c645b1a036590.ttf;--variations=0001=500;U+002E,U+0065;[period=0+681|e=1+650]
|
||||
|
|
|
@ -249,54 +249,55 @@ for filename in args:
|
|||
continue
|
||||
options = new_options
|
||||
|
||||
for font_funcs in [font_funcs] if font_funcs else all_whats("font-funcs"):
|
||||
extra_options = []
|
||||
for shaper in [shaper] if shaper else all_whats("shaper"):
|
||||
for font_funcs in [font_funcs] if font_funcs else all_whats("font-funcs"):
|
||||
extra_options = []
|
||||
|
||||
if shaper:
|
||||
extra_options.append("--shaper=" + shaper)
|
||||
if face_loader:
|
||||
extra_options.append("--face-loader=" + face_loader)
|
||||
if font_funcs:
|
||||
extra_options.append("--font-funcs=" + font_funcs)
|
||||
if shaper:
|
||||
extra_options.append("--shaper=" + shaper)
|
||||
if face_loader:
|
||||
extra_options.append("--face-loader=" + face_loader)
|
||||
if font_funcs:
|
||||
extra_options.append("--font-funcs=" + font_funcs)
|
||||
|
||||
if glyphs_expected != "*":
|
||||
extra_options.append("--verify")
|
||||
extra_options.append("--unsafe-to-concat")
|
||||
if glyphs_expected != "*":
|
||||
extra_options.append("--verify")
|
||||
extra_options.append("--unsafe-to-concat")
|
||||
|
||||
if verbose:
|
||||
print(
|
||||
"# shaper=%s face-loader=%s font-funcs=%s"
|
||||
% (shaper, face_loader, font_funcs)
|
||||
)
|
||||
cmd = [fontfile] + ["--unicodes", unicodes] + options + extra_options
|
||||
glyphs = shape_cmd(cmd, shape_process, verbose).strip()
|
||||
if verbose:
|
||||
print(
|
||||
"# shaper=%s face-loader=%s font-funcs=%s"
|
||||
% (shaper, face_loader, font_funcs)
|
||||
)
|
||||
cmd = [fontfile] + ["--unicodes", unicodes] + options + extra_options
|
||||
glyphs = shape_cmd(cmd, shape_process, verbose).strip()
|
||||
|
||||
if glyphs_expected == "*":
|
||||
passes += 1
|
||||
continue
|
||||
if glyphs_expected == "*":
|
||||
passes += 1
|
||||
continue
|
||||
|
||||
final_glyphs = glyphs
|
||||
final_glyphs_expected = glyphs_expected
|
||||
final_glyphs = glyphs
|
||||
final_glyphs_expected = glyphs_expected
|
||||
|
||||
if glyphs != glyphs_expected and glyphs.find("gid") != -1:
|
||||
if not no_glyph_names_process:
|
||||
no_glyph_names_process = open_shape_batch_process()
|
||||
if glyphs != glyphs_expected and glyphs.find("gid") != -1:
|
||||
if not no_glyph_names_process:
|
||||
no_glyph_names_process = open_shape_batch_process()
|
||||
|
||||
cmd2 = [fontfile] + ["--glyphs", "--no-glyph-names", glyphs]
|
||||
final_glyphs = shape_cmd(cmd2, no_glyph_names_process).strip()
|
||||
cmd2 = [fontfile] + ["--glyphs", "--no-glyph-names", glyphs]
|
||||
final_glyphs = shape_cmd(cmd2, no_glyph_names_process).strip()
|
||||
|
||||
cmd2 = [fontfile] + ["--glyphs", "--no-glyph-names", glyphs_expected]
|
||||
final_glyphs_expected = shape_cmd(cmd2, no_glyph_names_process).strip()
|
||||
cmd2 = [fontfile] + ["--glyphs", "--no-glyph-names", glyphs_expected]
|
||||
final_glyphs_expected = shape_cmd(cmd2, no_glyph_names_process).strip()
|
||||
|
||||
# If the removal of glyph_ids failed, fail the test.
|
||||
# https://github.com/harfbuzz/harfbuzz/issues/5169
|
||||
if not final_glyphs_expected or final_glyphs != final_glyphs_expected:
|
||||
print(hb_shape + " " + " ".join(cmd), file=sys.stderr)
|
||||
print("Actual: " + final_glyphs, file=sys.stderr)
|
||||
print("Expected: " + final_glyphs_expected, file=sys.stderr)
|
||||
fails += 1
|
||||
else:
|
||||
passes += 1
|
||||
# If the removal of glyph_ids failed, fail the test.
|
||||
# https://github.com/harfbuzz/harfbuzz/issues/5169
|
||||
if not final_glyphs_expected or final_glyphs != final_glyphs_expected:
|
||||
print(hb_shape + " " + " ".join(cmd), file=sys.stderr)
|
||||
print("Actual: " + final_glyphs, file=sys.stderr)
|
||||
print("Expected: " + final_glyphs_expected, file=sys.stderr)
|
||||
fails += 1
|
||||
else:
|
||||
passes += 1
|
||||
|
||||
print(
|
||||
"%d tests passed; %d failed; %d skipped." % (passes, fails, skips), file=sys.stderr
|
||||
|
|
Loading…
Add table
Reference in a new issue