diff --git a/lib/matplotlib/tests/test_backend_svg.py b/lib/matplotlib/tests/test_backend_svg.py index f655a56ca901..38116fab4fe7 100644 --- a/lib/matplotlib/tests/test_backend_svg.py +++ b/lib/matplotlib/tests/test_backend_svg.py @@ -9,7 +9,12 @@ import matplotlib.pyplot as plt from matplotlib.testing.decorators import cleanup -from matplotlib.testing.decorators import image_comparison +from matplotlib.testing.decorators import image_comparison, knownfailureif +import matplotlib + +needs_tex = knownfailureif( + not matplotlib.checkdep_tex(), + "This test needs a TeX installation") @cleanup @@ -173,6 +178,7 @@ def test_determinism_notex(): @cleanup +@needs_tex def test_determinism_tex(): # unique filename to allow for parallel testing _test_determinism('determinism_tex.svg', usetex=True) diff --git a/lib/matplotlib/textpath.py b/lib/matplotlib/textpath.py index c063c3ad9fa6..b69461917769 100644 --- a/lib/matplotlib/textpath.py +++ b/lib/matplotlib/textpath.py @@ -345,7 +345,7 @@ def get_glyphs_tex(self, prop, s, glyph_map=None, 1094995778)]: try: font.select_charmap(charmap_code) - except ValueError: + except (ValueError, RuntimeError): pass else: break