[interpolatable_test] Test VarComposite
This commit is contained in:
parent
0f1eb4673c
commit
b821141eb7
@ -35,9 +35,9 @@ class InterpolatableTest(unittest.TestCase):
|
|||||||
shutil.rmtree(self.tempdir)
|
shutil.rmtree(self.tempdir)
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def get_test_input(test_file_or_folder):
|
def get_test_input(*test_file_or_folder):
|
||||||
path, _ = os.path.split(__file__)
|
path, _ = os.path.split(__file__)
|
||||||
return os.path.join(path, "data", test_file_or_folder)
|
return os.path.join(path, "data", *test_file_or_folder)
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def get_file_list(folder, suffix, prefix=""):
|
def get_file_list(folder, suffix, prefix=""):
|
||||||
@ -93,6 +93,15 @@ class InterpolatableTest(unittest.TestCase):
|
|||||||
otf_paths = self.get_file_list(self.tempdir, suffix)
|
otf_paths = self.get_file_list(self.tempdir, suffix)
|
||||||
self.assertIsNone(interpolatable_main(otf_paths))
|
self.assertIsNone(interpolatable_main(otf_paths))
|
||||||
|
|
||||||
|
def test_interpolatable_varComposite(self):
|
||||||
|
input_path = self.get_test_input(
|
||||||
|
"..", "..", "ttLib", "data", "varc-ac00-ac01.ttf"
|
||||||
|
)
|
||||||
|
# This particular test font which was generated by machine-learning
|
||||||
|
# exhibits an "error" in one of the masters; it's a false-positive.
|
||||||
|
# Just make sure the code runs.
|
||||||
|
interpolatable_main((input_path,))
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
sys.exit(unittest.main())
|
sys.exit(unittest.main())
|
||||||
|
Loading…
x
Reference in New Issue
Block a user