summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_imp.py
diff options
context:
space:
mode:
authorBrett Cannon <brett@python.org>2013-06-16 17:13:40 (GMT)
committerBrett Cannon <brett@python.org>2013-06-16 17:13:40 (GMT)
commite4f41deccf94ccc798b1eb1f44657ade66669a60 (patch)
tree8f47ca73224c628f4afcebb9dd989cac73d0f8d1 /Lib/test/test_imp.py
parent39295e7a55d03b9ef31c0d0dd27d129b1ad5a695 (diff)
downloadcpython-e4f41deccf94ccc798b1eb1f44657ade66669a60.zip
cpython-e4f41deccf94ccc798b1eb1f44657ade66669a60.tar.gz
cpython-e4f41deccf94ccc798b1eb1f44657ade66669a60.tar.bz2
Issue #17177: The imp module is pending deprecation.
To make sure there is no issue with code that is both Python 2 and 3 compatible, there are no plans to remove the module any sooner than Python 4 (unless the community moves to Python 3 solidly before then).
Diffstat (limited to 'Lib/test/test_imp.py')
-rw-r--r--Lib/test/test_imp.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/test/test_imp.py b/Lib/test/test_imp.py
index dc62423..cf50ea4 100644
--- a/Lib/test/test_imp.py
+++ b/Lib/test/test_imp.py
@@ -2,7 +2,6 @@ try:
import _thread
except ImportError:
_thread = None
-import imp
import importlib
import os
import os.path
@@ -11,6 +10,9 @@ import sys
from test import support
import unittest
import warnings
+with warnings.catch_warnings():
+ warnings.simplefilter('ignore', PendingDeprecationWarning)
+ import imp
def requires_load_dynamic(meth):