we need pytest 3 for some tests use `pytest.approx()`.
we no longer need patched bumpversion, as we now call `git tag` ourselves (in `python setup.py release`)
Previously, we were using --pyargs to make sure pytest would run the test suite against the installed package, because our tests
were embedded inside the package and hence importable.
Now that they are placed in an external folder, that option is not needed.
pytest without options will run all the test modules from the default test paths as defined in setup.cfg, i.e Tests/ folder.
The tests will be run against the installed fontTools in the current tox environment.
We also pass {posargs} in the 'htmlcov' tox env, to allow passing extra options after `tox -e htmlcov -- {posargs}` to the `coverage html` command.
We should probably use cliTools.makeOutputFileName here for consistency with ttx,
but I know some prefer the approach taken by pyftsubset so I don't want force this.
Howver, I find it a bit annoying that when one is too lazy (like me) to specify
the --output-file=, the subsetter outputs a file ending with an invalid ".subset" extension, which Finder or Windows Explorer don't recongize as a font, and so one has to rename it anyway.
This makes the '.subset' string is inserted between the file name and its original extension (if any).
The code in main() assumes that the first of the args which are not consumed by Options.parse_opts(args) is the positional argument (ie. does not start with '--') for the input font file, and that is what the usage() says too.
However I find it myself writing --options=... first, and then at the end the positional arguments, as is the convention for many other Unix tools.
This patch makes this possible, while also keeping the current behavior.
Rounding of coordinates is now disabled by default.
The pen now accepts an optional 'roundTolerance' float, with values between
0 and 1 (default is 0).
Values >= 0.5 mean round all coordinates to integers.
Values between 0 and 0.5 mean round only when the absolute difference
between the original float and the rounded integer is within the tolerance
Fixes#769
* [feaLib.ast] fix checking multiple markClass definitions don't redefine same glyphs
As pointed out by @mhosken, we are looking in the wrong list for glyphs
that have already been defined in a previous markClass definition.
With this patch, the current markClass.fea test case fails becuase it defines 'acute'
twice for the same @TOP_MARKS class:
fontTools.feaLib.error.FeatureLibError: Lib/fontTools/feaLib/testdata/markClass.fea:6:5: Glyph acute already defined at Lib/fontTools/feaLib/testdata/markClass.fea:3:1
Also see conversation at:
3b79d51755 (r94622074)
* feaLib/testdat/markClass.fea: remove duplicate 'acute' in @TOP_MARKS
Now the test pass, after 45c77b7
* [feaLib.builder_test] test case for redefined glyph in multiple markClass definitions
This should be a bit more efficient as we don't need to create a temporary list
object before passing it to "".join() method of str; the latter accepts any
Iterable