8000 Backport PR #13194: TST: Fix incorrect call to pytest.raises. · matplotlib/matplotlib@b6d0795 · GitHub
[go: up one dir, main page]

Skip to content

Commit b6d0795

Browse files
QuLogicMeeseeksDev[bot]
authored andcommitted
Backport PR #13194: TST: Fix incorrect call to pytest.raises.
1 parent 73a7c0c commit b6d0795

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/matplotlib/tests/test_figure.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -365,8 +365,8 @@ def test_subplots_shareax_loglabels():
365365

366366
def test_savefig():
367367
fig = plt.figure()
368-
msg = "savefig() takes 2 positional arguments but 3 were given"
369-
with pytest.raises(TypeError, message=msg):
368+
msg = r"savefig\(\) takes 2 positional arguments but 3 were given"
369+
with pytest.raises(TypeError, match=msg):
370370
fig.savefig("fname1.png", "fname2.png")
371371

372372

0 commit comments

Comments
 (0)
0