Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit ee7bac4

Browse files
committed
Remove warnings control from tests.py.
We already perform such warnings handling in conftest.py, which will be executed by matplotlib.test, so no need to dupe it here.
1 parent 8ac3ea1 commit ee7bac4

File tree

1 file changed

+0
-23
lines changed

1 file changed

+0
-23
lines changed

tests.py

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -13,29 +13,6 @@
1313

1414

1515
if __name__ == '__main__':
16-
17-
import dateutil.parser
18-
try:
19-
import setuptools
20-
except ImportError:
21-
pass
22-
23-
# The warnings need to be before any of matplotlib imports, but after
24-
# dateutil.parser and setuptools (if present) which has syntax error with
25-
# the warnings enabled. Filtering by module does not work as this will be
26-
# raised by Python itself so `module=matplotlib.*` is out of question.
27-
28-
import warnings
29-
30-
# Python 3.6 deprecate invalid character-pairs \A, \* ... in non
31-
# raw-strings and other things. Let's not re-introduce them
32-
warnings.filterwarnings('error', '.*invalid escape sequence.*',
33-
category=DeprecationWarning)
34-
warnings.filterwarnings(
35-
'default',
36-
r'.*inspect.getargspec\(\) is deprecated.*',
37-
category=DeprecationWarning)
38-
3916
from matplotlib import test
4017

4118
parser = argparse.ArgumentParser(add_help=False)

0 commit comments

Comments
 (0)