8000 Add note about disabling warnings in test_rcparams · matplotlib/matplotlib@669c379 · GitHub
[go: up one dir, main page]

Skip to content
Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 669c379

Browse files
committed
Add note about disabling warnings in test_rcparams
1 parent 155e1f7 commit 669c379

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

lib/matplotlib/tests/test_rcparams.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,13 @@ def test_Bug_2543():
101101
# This was not possible because validate_bool_maybe_none did not
102102
# accept None as an argument.
103103
# https://github.com/matplotlib/matplotlib/issues/2543
104+
# We filter warnings at this stage since a number of them are raised
105+
# for deprecated rcparams as they should. We dont want these in the
106+
# printed in the test suite.
104107
with warnings.catch_warnings():
105-
warnings.filterwarnings('ignore', message='.*(deprecated|obsolete)', category=UserWarning)
108+
warnings.filterwarnings('ignore',
109+
message='.*(deprecated|obsolete)',
110+
category=UserWarning)
106111
with mpl.rc_context():
107112
_copy = mpl.rcParams.copy()
108113
for key in six.iterkeys(_copy):

0 commit comments

Comments
 (0)
0