Ticket #11290: cycle_mult.patch
File cycle_mult.patch, 970 bytes (added by , 15 years ago) |
---|
-
tests/regressiontests/templates/tests.py
156 156 split = token.split_contents() 157 157 self.assertEqual(split, ["sometag", '_("Page not found")', 'value|yesno:_("yes,no")']) 158 158 159 def test_cycle_multiple_render(self): 160 t = template.Template("{% cycle a,b,c as abc %}{% cycle abc %}") 161 c = template.Context({}) 162 self.assertEqual(t.render(c), t.render(c)) 163 164 t = template.Template("{% for letter in abc %}{% cycle 'd' 'e' 'f' 'g' %}{% endfor %}") 165 c = template.Context({"abc": ("a", "b", "c")}) 166 self.assertEqual(t.render(c), t.render(c)) 167 159 168 def test_url_reverse_no_settings_module(self): 160 169 # Regression test for #9005 161 170 from django.template import Template, Context, TemplateSyntaxError