summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2015-01-18 18:32:47 -0500
committerTim Graham <timograham@gmail.com>2015-01-18 18:33:56 -0500
commit663db8ea2adfd47dda50726404401ff2d290db52 (patch)
treea41e96481ed868c4fd00310f8ee6d6f46d41dcfa
parent559e15a23a7e1f2437de001e7eda2e2fa0723fb3 (diff)
[1.8.x] Removed usage of deprecated removetags in a template test.
Backport of b84100e8e22b175b62ce849acbcf1fa9a1e0e5b8 from master
-rw-r--r--tests/template_tests/syntax_tests/test_filter_syntax.py10
1 files changed, 4 insertions, 6 deletions
diff --git a/tests/template_tests/syntax_tests/test_filter_syntax.py b/tests/template_tests/syntax_tests/test_filter_syntax.py
index 58ee527758..94e7fe2871 100644
--- a/tests/template_tests/syntax_tests/test_filter_syntax.py
+++ b/tests/template_tests/syntax_tests/test_filter_syntax.py
@@ -2,8 +2,7 @@
from __future__ import unicode_literals
from django.template import TemplateSyntaxError
-from django.test import SimpleTestCase, ignore_warnings
-from django.utils.deprecation import RemovedInDjango20Warning
+from django.test import SimpleTestCase
from ..utils import setup, SomeClass, SomeOtherException, UTF8Class
@@ -75,14 +74,13 @@ class FilterSyntaxTests(SimpleTestCase):
with self.assertRaises(TemplateSyntaxError):
self.engine.get_template('filter-syntax08')
- @ignore_warnings(category=RemovedInDjango20Warning)
- @setup({'filter-syntax09': '{{ var|removetags:"b i"|upper|lower }}'})
+ @setup({'filter-syntax09': '{{ var|cut:"o"|upper|lower }}'})
def test_filter_syntax09(self):
"""
Chained filters, with an argument to the first one
"""
- output = self.engine.render_to_string('filter-syntax09', {'var': '<b><i>Yes</i></b>'})
- self.assertEqual(output, 'yes')
+ output = self.engine.render_to_string('filter-syntax09', {'var': 'Foo'})
+ self.assertEqual(output, 'f')
@setup({'filter-syntax10': r'{{ var|default_if_none:" endquote\" hah" }}'})
def test_filter_syntax10(self):