aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWaylan Limberg <waylan.limberg@icloud.com>2018-01-03 20:29:48 -0500
committerWaylan Limberg <waylan.limberg@icloud.com>2018-01-04 14:47:58 -0500
commita7d211b53afbdb3c3febf881127dfbea4da422ee (patch)
treea772207f1f2268b3b49c4db45024b10344b7d47a
parent2e9beaecae75ec01899afa846f775ba7b3105ff8 (diff)
downloadmarkdown-a7d211b53afbdb3c3febf881127dfbea4da422ee.tar.gz
markdown-a7d211b53afbdb3c3febf881127dfbea4da422ee.tar.bz2
markdown-a7d211b53afbdb3c3febf881127dfbea4da422ee.zip
Warnings should cause tests to fail.
-rw-r--r--tests/__init__.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/__init__.py b/tests/__init__.py
index f759ceb..6826ff3 100644
--- a/tests/__init__.py
+++ b/tests/__init__.py
@@ -2,6 +2,7 @@ import os
import markdown
import codecs
import difflib
+import warnings
try:
import nose
except ImportError as e:
@@ -179,4 +180,10 @@ def generate_all():
def run():
+ # Warnings should cause tests to fail...
+ warnings.simplefilter('error')
+ # Except for the warnings that shouldn't
+ warnings.filterwarnings('default', category=PendingDeprecationWarning)
+ warnings.filterwarnings('default', category=DeprecationWarning, module='markdown')
+
nose.main(addplugins=[HtmlOutput(), Markdown()])