From bedf10a98dfe46dda39e8a20530f7476e7df90ff Mon Sep 17 00:00:00 2001 From: Adrian Holovaty Date: Tue, 22 Nov 2005 05:44:04 +0000 Subject: Fixed #598 -- Added {% include %} template tag. Added docs and unit tests. Thanks, rjwittams git-svn-id: http://code.djangoproject.com/svn/django/trunk@1349 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- tests/othertests/templates.py | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tests') diff --git a/tests/othertests/templates.py b/tests/othertests/templates.py index 729105d8fc..1211cde86b 100644 --- a/tests/othertests/templates.py +++ b/tests/othertests/templates.py @@ -134,6 +134,12 @@ TEMPLATE_TESTS = { 'ifnotequal03': ("{% ifnotequal a b %}yes{% else %}no{% endifnotequal %}", {"a": 1, "b": 2}, "yes"), 'ifnotequal04': ("{% ifnotequal a b %}yes{% else %}no{% endifnotequal %}", {"a": 1, "b": 1}, "no"), + ### INCLUDE TAG ########################################################### + 'include01': ('{% include "basic-syntax01" %}', {}, "something cool"), + 'include02': ('{% include "basic-syntax02" %}', {'headline': 'Included'}, "Included"), + 'include03': ('{% include template_name %}', {'template_name': 'basic-syntax02', 'headline': 'Included'}, "Included"), + 'include04': ('a{% include "nonexistent" %}b', {}, "ab"), + ### INHERITANCE ########################################################### # Standard template with no inheritance -- cgit v1.3