[varLib tests] Rename test files
This commit is contained in:
parent
23f9a293d9
commit
bfccdbb5d5
@ -9,7 +9,7 @@ class DesignspaceTest(unittest.TestCase):
|
||||
def test_load(self):
|
||||
self.maxDiff = None
|
||||
self.assertEqual(
|
||||
designspace.load(_getpath("DesignspaceTest.designspace")),
|
||||
designspace.load(_getpath("Designspace.designspace")),
|
||||
|
||||
{'sources':
|
||||
[{'location': {'weight': 0.0},
|
||||
@ -55,7 +55,7 @@ class DesignspaceTest(unittest.TestCase):
|
||||
|
||||
def test_load2(self):
|
||||
self.assertEqual(
|
||||
designspace.load(_getpath("DesignspaceTest2.designspace")),
|
||||
designspace.load(_getpath("Designspace2.designspace")),
|
||||
{'sources': [], 'instances': [{}]})
|
||||
|
||||
|
||||
|
@ -95,7 +95,7 @@ class InterpolateLayoutTest(unittest.TestCase):
|
||||
base master.
|
||||
"""
|
||||
suffix = '.ttf'
|
||||
ds_path = self.get_test_input('InterpolateLayoutTest.designspace')
|
||||
ds_path = self.get_test_input('InterpolateLayout.designspace')
|
||||
ufo_dir = self.get_test_input('master_ufo')
|
||||
ttx_dir = self.get_test_input('master_ttx_interpolatable_ttf')
|
||||
|
||||
|
@ -85,7 +85,7 @@ class MutatorTest(unittest.TestCase):
|
||||
|
||||
def test_varlib_mutator_ttf(self):
|
||||
suffix = '.ttf'
|
||||
ds_path = self.get_test_input('BuildTest.designspace')
|
||||
ds_path = self.get_test_input('Build.designspace')
|
||||
ufo_dir = self.get_test_input('master_ufo')
|
||||
ttx_dir = self.get_test_input('master_ttx_interpolatable_ttf')
|
||||
|
||||
@ -96,7 +96,7 @@ class MutatorTest(unittest.TestCase):
|
||||
|
||||
finder = lambda s: s.replace(ufo_dir, self.tempdir).replace('.ufo', suffix)
|
||||
varfont, _, _ = build(ds_path, finder)
|
||||
varfont_path = os.path.join(self.tempdir, 'MutatorTest' + suffix)
|
||||
varfont_path = os.path.join(self.tempdir, 'Mutator' + suffix)
|
||||
varfont.save(varfont_path)
|
||||
|
||||
args = [varfont_path, 'wght=500', 'cntr=50']
|
||||
@ -105,7 +105,7 @@ class MutatorTest(unittest.TestCase):
|
||||
instfont_path = os.path.splitext(varfont_path)[0] + '-instance' + suffix
|
||||
instfont = TTFont(instfont_path)
|
||||
tables = [table_tag for table_tag in instfont.keys() if table_tag != 'head']
|
||||
expected_ttx = self.get_test_input('MutatorTest.ttx')
|
||||
expected_ttx = self.get_test_input('Mutator.ttx')
|
||||
self.expect_ttx(instfont, expected_ttx, tables)
|
||||
|
||||
|
||||
|
@ -84,7 +84,7 @@ class BuildTest(unittest.TestCase):
|
||||
|
||||
def test_varlib_build_ttf(self):
|
||||
suffix = '.ttf'
|
||||
ds_path = self.get_test_input('BuildTest.designspace')
|
||||
ds_path = self.get_test_input('Build.designspace')
|
||||
ufo_dir = self.get_test_input('master_ufo')
|
||||
ttx_dir = self.get_test_input('master_ttx_interpolatable_ttf')
|
||||
|
||||
@ -97,11 +97,11 @@ class BuildTest(unittest.TestCase):
|
||||
varfont, model, _ = build(ds_path, finder)
|
||||
|
||||
tables = ['GDEF', 'HVAR', 'fvar', 'gvar']
|
||||
expected_ttx = self.get_test_input('BuildTest.ttx')
|
||||
expected_ttx = self.get_test_input('Build.ttx')
|
||||
self.expect_ttx(varfont, expected_ttx, tables)
|
||||
|
||||
# ensure the TTX dump is the same after saving and reloading font
|
||||
varfont_path = os.path.join(self.tempdir, 'BuildTest.ttf')
|
||||
varfont_path = os.path.join(self.tempdir, 'Build.ttf')
|
||||
varfont.save(varfont_path)
|
||||
self.expect_ttx(TTFont(varfont_path), expected_ttx, tables)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user