Skip to content

Commit 6d48325

Browse files
committed
Add test for pgf.documentclass rcParam in PGF backend
1 parent 89f6d80 commit 6d48325

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

lib/matplotlib/tests/test_backend_pgf.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -400,3 +400,12 @@ def test_document_font_size():
400400
label=r'\normalsize the document font size is \the\fontdimen6\font'
401401
)
402402
plt.legend()
403+
404+
405+
@pytest.mark.backend("pgf")
406+
def test_pgf_documentclass_written():
407+
from matplotlib.backends.backend_pgf import LatexManager
408+
409+
mpl.rcParams["pgf.documentclass"] = "IEEEtran"
410+
header = LatexManager._build_latex_header()
411+
assert r"\documentclass{IEEEtran}" in header

0 commit comments

Comments
 (0)