diff options
Diffstat (limited to 'tests/template_tests/syntax_tests/test_include.py')
| -rw-r--r-- | tests/template_tests/syntax_tests/test_include.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/template_tests/syntax_tests/test_include.py b/tests/template_tests/syntax_tests/test_include.py index ca98e09771..8587639674 100644 --- a/tests/template_tests/syntax_tests/test_include.py +++ b/tests/template_tests/syntax_tests/test_include.py @@ -182,6 +182,15 @@ class IncludeTagTests(SimpleTestCase): with self.assertRaises(TemplateSyntaxError): template.render(context) + @setup({'include_empty': '{% include %}'}) + def test_include_empty(self): + msg = ( + "'include' tag takes at least one argument: the name of the " + "template to be included." + ) + with self.assertRaisesMessage(TemplateSyntaxError, msg): + self.engine.get_template('include_empty') + class IncludeTests(SimpleTestCase): |
