From 17123eaf6eb72a60bf6c5b8a1ad0457187387879 Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Sat, 31 Jan 2015 11:55:37 -0500 Subject: Only log warnings from commandline script. I need to remember this is a lib first and not configure logging from within the lib. Also, from the script we are now actually displaying deprecation warnings. For some reason I don't understnad deprecation warnings are hidden by default in Python. And who remembers to run Python with the `-Wd` flag every time they upgrade a lib just to make sure there's no new deprecations? Fixes #384. --- tests/test_apis.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'tests') diff --git a/tests/test_apis.py b/tests/test_apis.py index 4ed2990..e3de779 100644 --- a/tests/test_apis.py +++ b/tests/test_apis.py @@ -15,7 +15,7 @@ import types import markdown import warnings from markdown.__main__ import parse_options -from logging import DEBUG, INFO, CRITICAL +from logging import DEBUG, WARNING, CRITICAL import yaml import tempfile @@ -613,7 +613,6 @@ class TestCliOptionParsing(unittest.TestCase): 'input': None, 'output': None, 'encoding': None, - 'safe_mode': False, 'output_format': 'xhtml1', 'lazy_ol': True, 'extensions': [], @@ -636,7 +635,7 @@ class TestCliOptionParsing(unittest.TestCase): def testVerboseOption(self): options, logging_level = parse_options(['-v']) - self.assertEqual(logging_level, INFO) + self.assertEqual(logging_level, WARNING) def testNoisyOption(self): options, logging_level = parse_options(['--noisy']) -- cgit v1.2.3