mirror of
https://github.com/django/django.git
synced 2025-10-24 14:16:09 +00:00
Refs #32290 -- Added {% extends %} test for relative path in variable.
This commit is contained in:
committed by
Mariusz Felisiak
parent
f4272d000a
commit
640a6e1dce
@@ -16,6 +16,12 @@ class ExtendsRelativeBehaviorTests(SimpleTestCase):
|
||||
output = template.render(Context({}))
|
||||
self.assertEqual(output.strip(), 'three two one')
|
||||
|
||||
def test_normal_extend_variable(self):
|
||||
engine = Engine(dirs=[RELATIVE])
|
||||
template = engine.get_template('one_var.html')
|
||||
output = template.render(Context({'tmpl': './two.html'}))
|
||||
self.assertEqual(output.strip(), 'three two one')
|
||||
|
||||
def test_dir1_extend(self):
|
||||
engine = Engine(dirs=[RELATIVE])
|
||||
template = engine.get_template('dir1/one.html')
|
||||
|
||||
Reference in New Issue
Block a user