summaryrefslogtreecommitdiff
path: root/nose/config.py
diff options
context:
space:
mode:
authorwiggin15 <wiggin15@yahoo.com>2013-04-09 19:00:45 +0300
committerArnon Yaari <arnony@infinidat.com>2013-05-29 14:20:33 +0300
commit68a26dda91f16f1e0474a4d3d24802a8db1c4b29 (patch)
treea7cb64b569f81996a7315bb1ef7e7cdd47eb6e78 /nose/config.py
parentf59cda79adc4dfa87c40a3f7939e21533caab186 (diff)
downloadnose-68a26dda91f16f1e0474a4d3d24802a8db1c4b29.tar.gz
fix suppressed deprecation warning
Python's default warning filter suppresses deprecation warnings; Change the filter to make the warnings in nose.config visible.
Diffstat (limited to 'nose/config.py')
-rw-r--r--nose/config.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/nose/config.py b/nose/config.py
index 456f35b..979fe3b 100644
--- a/nose/config.py
+++ b/nose/config.py
@@ -7,7 +7,7 @@ import ConfigParser
from optparse import OptionParser
from nose.util import absdir, tolist
from nose.plugins.manager import NoPlugins
-from warnings import warn
+from warnings import warn, filterwarnings
log = logging.getLogger(__name__)
@@ -25,6 +25,8 @@ config_files = [
# Windows and IronPython
exe_allowed_platforms = ('win32', 'cli')
+filterwarnings("always", category=DeprecationWarning,
+ module=r'(.*\.)?nose\.config')
class NoSuchOptionError(Exception):
def __init__(self, name):
@@ -431,6 +433,7 @@ class Config(object):
"the -w argument on the command line, or by using the "
"--tests argument in a configuration file.",
DeprecationWarning)
+ warned = True
self.testNames.append(path)
def default(self):