diff --git a/lib/matplotlib/tests/baseline_images/test_backend_pdf/pdf_use14corefonts.pdf b/lib/matplotlib/tests/baseline_images/test_backend_pdf/pdf_use14corefonts.pdf index bbe66a67bcc2..5cdc2e34e25d 100644 Binary files a/lib/matplotlib/tests/baseline_images/test_backend_pdf/pdf_use14corefonts.pdf and b/lib/matplotlib/tests/baseline_images/test_backend_pdf/pdf_use14corefonts.pdf differ diff --git a/lib/matplotlib/tests/test_backend_pdf.py b/lib/matplotlib/tests/test_backend_pdf.py index 2feee6fb1238..dad45bd38ee9 100644 --- a/lib/matplotlib/tests/test_backend_pdf.py +++ b/lib/matplotlib/tests/test_backend_pdf.py @@ -15,19 +15,27 @@ from matplotlib.testing.decorators import (image_comparison, knownfailureif, cleanup) -if 'TRAVIS' not in os.environ: - @image_comparison(baseline_images=['pdf_use14corefonts'], - extensions=['pdf']) - def test_use14corefonts(): - rcParams['pdf.use14corefonts'] = True - rcParams['font.family'] = 'sans-serif' - rcParams['font.size'] = 8 - rcParams['font.sans-serif'] = ['Helvetica'] - rcParams['pdf.compression'] = 0 - - text = '''A three-line text positioned just above a blue line - and containing some French characters and the euro symbol: - "Merci pépé pour les 10 €"''' + +@image_comparison(baseline_images=['pdf_use14corefonts'], + extensions=['pdf']) +def test_use14corefonts(): + rcParams['pdf.use14corefonts'] = True + rcParams['font.family'] = 'sans-serif' + rcParams['font.size'] = 8 + rcParams['font.sans-serif'] = ['Helvetica'] + rcParams['pdf.compression'] = 0 + + text = '''A three-line text positioned just above a blue line +and containing some French characters and the euro symbol: +"Merci pépé pour les 10 €"''' + + fig = plt.figure() + ax = fig.add_subplot(1, 1, 1) + ax.set_title('Test PDF backend with option use14corefonts=True') + ax.text(0.5, 0.5, text, horizontalalignment='center', + verticalalignment='bottom', + fontsize=14) + ax.axhline(0.5, linewidth=0.5) @cleanup