diff --git a/test/subset/data/Makefile.sources b/test/subset/data/Makefile.sources index dd1bcfe7a..75913fd9f 100644 --- a/test/subset/data/Makefile.sources +++ b/test/subset/data/Makefile.sources @@ -2,6 +2,7 @@ TESTS = \ tests/basics.tests \ tests/full-font.tests \ tests/japanese.tests \ + tests/layout.tests \ $(NULL) XFAIL_TESTS = \ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.41,42,43.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.41,42,43.ttf new file mode 100644 index 000000000..aa007bac5 Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.41,42,43.ttf differ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.41,43.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.41,43.ttf new file mode 100644 index 000000000..f3be30c5b Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.41,43.ttf differ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.41.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.41.ttf new file mode 100644 index 000000000..44c329eb1 Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.41.ttf differ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.43.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.43.ttf new file mode 100644 index 000000000..b0a1ea3dc Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.43.ttf differ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.CA,CB.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.CA,CB.ttf new file mode 100644 index 000000000..16ad9d515 Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout-retain-gids.CA,CB.ttf differ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.41,42,43.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.41,42,43.ttf new file mode 100644 index 000000000..d0d9d5a28 Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.41,42,43.ttf differ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.41,43.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.41,43.ttf new file mode 100644 index 000000000..f4d881f29 Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.41,43.ttf differ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.41.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.41.ttf new file mode 100644 index 000000000..9e6dd28f5 Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.41.ttf differ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.43.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.43.ttf new file mode 100644 index 000000000..50260c54d Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.43.ttf differ diff --git a/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.CA,CB.ttf b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.CA,CB.ttf new file mode 100644 index 000000000..22d5b6198 Binary files /dev/null and b/test/subset/data/expected/layout/Roboto-Regular.smallcaps.keep-layout.CA,CB.ttf differ diff --git a/test/subset/data/fonts/Roboto-Regular.smallcaps.ttf b/test/subset/data/fonts/Roboto-Regular.smallcaps.ttf new file mode 100644 index 000000000..fc58299ba Binary files /dev/null and b/test/subset/data/fonts/Roboto-Regular.smallcaps.ttf differ diff --git a/test/subset/data/profiles/keep-layout-retain-gids.txt b/test/subset/data/profiles/keep-layout-retain-gids.txt new file mode 100644 index 000000000..f4787adef --- /dev/null +++ b/test/subset/data/profiles/keep-layout-retain-gids.txt @@ -0,0 +1,2 @@ +--drop-tables-=GSUB,GPOS +--retain-gids diff --git a/test/subset/data/profiles/keep-layout.txt b/test/subset/data/profiles/keep-layout.txt new file mode 100644 index 000000000..56da0ffe3 --- /dev/null +++ b/test/subset/data/profiles/keep-layout.txt @@ -0,0 +1 @@ +--drop-tables-=GSUB,GPOS diff --git a/test/subset/data/tests/full-font.tests b/test/subset/data/tests/full-font.tests index ff195cead..225bb484a 100644 --- a/test/subset/data/tests/full-font.tests +++ b/test/subset/data/tests/full-font.tests @@ -9,4 +9,3 @@ SUBSETS: abc Ǽ!A bc ×ØÙÚÞ - diff --git a/test/subset/data/tests/layout.tests b/test/subset/data/tests/layout.tests new file mode 100644 index 000000000..dd1c26ee9 --- /dev/null +++ b/test/subset/data/tests/layout.tests @@ -0,0 +1,13 @@ +FONTS: +Roboto-Regular.smallcaps.ttf + +PROFILES: +keep-layout.txt +keep-layout-retain-gids.txt + +SUBSETS: +ABC +AC +C +A +ÊË diff --git a/test/subset/generate-expected-outputs.py b/test/subset/generate-expected-outputs.py index 6d11cbfe6..804ed7170 100755 --- a/test/subset/generate-expected-outputs.py +++ b/test/subset/generate-expected-outputs.py @@ -19,14 +19,15 @@ def usage(): def generate_expected_output(input_file, unicodes, profile_flags, output_path): args = ["fonttools", "subset", input_file] - args.extend(profile_flags) args.extend(["--notdef-outline", "--name-IDs=*", "--name-languages=*", "--name-legacy", "--drop-tables+=DSIG,GPOS,GSUB,GDEF", + "--layout-features=*", "--unicodes=%s" % unicodes, "--output-file=%s" % output_path]) + args.extend(profile_flags) check_call(args)