summaryrefslogtreecommitdiff
path: root/tests/run.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/run.py')
-rw-r--r--tests/run.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/tests/run.py b/tests/run.py
index 07665b2a..edebc7a1 100644
--- a/tests/run.py
+++ b/tests/run.py
@@ -8,7 +8,7 @@
python run.py [testfile ...]
- :copyright: Copyright 2006-2017 by the Pygments team, see AUTHORS.
+ :copyright: Copyright 2006-2019 by the Pygments team, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
@@ -16,11 +16,19 @@ from __future__ import print_function
import os
import sys
+import warnings
# only find tests in this directory
if os.path.dirname(__file__):
os.chdir(os.path.dirname(__file__))
+# make FutureWarnings (coming from Regex syntax most likely) and
+# DeprecationWarnings due to non-raw strings an error
+warnings.filterwarnings("error", module=r"pygments\..*",
+ category=FutureWarning)
+warnings.filterwarnings("error", module=r".*pygments.*",
+ category=DeprecationWarning)
+
try:
import nose