summaryrefslogtreecommitdiff
path: root/tests/template_backends
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2017-01-19 21:10:33 -0500
committerAymeric Augustin <aymeric.augustin@m4x.org>2017-01-20 08:49:47 +0100
commit109b33f64c8d3f48c9e0bd3ea8d42fe6f3cb02b7 (patch)
treece4c2311d5993e2e6b70062530834269314c0eb1 /tests/template_backends
parentdc8834cad41aa407f402dc54788df3cd37ab3e22 (diff)
downloaddjango-109b33f64c8d3f48c9e0bd3ea8d42fe6f3cb02b7.tar.gz
Refs #23919 -- Simplified assertRaisesRegex()'s that accounted for Python 2.
Diffstat (limited to 'tests/template_backends')
-rw-r--r--tests/template_backends/test_utils.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/template_backends/test_utils.py b/tests/template_backends/test_utils.py
index d1f3aaa793..d0bd01cdc2 100644
--- a/tests/template_backends/test_utils.py
+++ b/tests/template_backends/test_utils.py
@@ -11,9 +11,9 @@ class TemplateUtilsTests(SimpleTestCase):
Failing to import a backend keeps raising the original import error
(#24265).
"""
- with self.assertRaisesRegex(ImportError, "No module named '?raise"):
+ with self.assertRaisesMessage(ImportError, "No module named 'raise"):
engines.all()
- with self.assertRaisesRegex(ImportError, "No module named '?raise"):
+ with self.assertRaisesMessage(ImportError, "No module named 'raise"):
engines.all()
@override_settings(TEMPLATES=[{