mirror of
https://github.com/django/django.git
synced 2025-07-24 05:36:15 +00:00
Fixed #20650 -- Fixed {% filter %} incorrectly accepting 'escape' as argument
Thanks to grzesiof for the report and to loic84 and Alex Gaynor for the review.
This commit is contained in:
parent
b91787910c
commit
ec371ace00
3 changed files with 8 additions and 2 deletions
|
@ -854,6 +854,10 @@ class TemplateTests(TransRealMixin, TestCase):
|
|||
'filter02': ('{% filter upper %}django{% endfilter %}', {}, 'DJANGO'),
|
||||
'filter03': ('{% filter upper|lower %}django{% endfilter %}', {}, 'django'),
|
||||
'filter04': ('{% filter cut:remove %}djangospam{% endfilter %}', {'remove': 'spam'}, 'django'),
|
||||
'filter05': ('{% filter safe %}fail{% endfilter %}', {}, template.TemplateSyntaxError),
|
||||
'filter05bis': ('{% filter upper|safe %}fail{% endfilter %}', {}, template.TemplateSyntaxError),
|
||||
'filter06': ('{% filter escape %}fail{% endfilter %}', {}, template.TemplateSyntaxError),
|
||||
'filter06bis': ('{% filter upper|escape %}fail{% endfilter %}', {}, template.TemplateSyntaxError),
|
||||
|
||||
### FIRSTOF TAG ###########################################################
|
||||
'firstof01': ('{% firstof a b c %}', {'a':0,'b':0,'c':0}, ''),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue