From ec808e807ad711b993f199f6b4165ac6d0e1125b Mon Sep 17 00:00:00 2001 From: Claude Paroz Date: Fri, 6 Mar 2015 21:56:11 +0100 Subject: Fixed urlize regression with entities in query strings Refs #22267. Thanks Shai Berger for spotting the issue and Tim Graham for the initial patch. --- tests/template_tests/filter_tests/test_urlize.py | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'tests') diff --git a/tests/template_tests/filter_tests/test_urlize.py b/tests/template_tests/filter_tests/test_urlize.py index 716bf9e6f5..1c55d64751 100644 --- a/tests/template_tests/filter_tests/test_urlize.py +++ b/tests/template_tests/filter_tests/test_urlize.py @@ -73,6 +73,14 @@ class UrlizeTests(SimpleTestCase): 'Email me at <me@example.com>', ) + @setup({'urlize09': '{% autoescape off %}{{ a|urlize }}{% endautoescape %}'}) + def test_urlize09(self): + output = self.engine.render_to_string('urlize09', {'a': "http://example.com/?x=&y=<2>"}) + self.assertEqual( + output, + 'http://example.com/?x=&y=<2>', + ) + class FunctionTests(SimpleTestCase): -- cgit v1.3