diff options
Diffstat (limited to 'vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from.test')
-rw-r--r-- | vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from.test | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from.test b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from.test new file mode 100644 index 00000000..205f5918 --- /dev/null +++ b/vendor/twig/twig/test/Twig/Tests/Fixtures/tags/macro/from.test | |||
@@ -0,0 +1,18 @@ | |||
1 | --TEST-- | ||
2 | "macro" tag | ||
3 | --TEMPLATE-- | ||
4 | {% from 'forms.twig' import foo %} | ||
5 | {% from 'forms.twig' import foo as foobar, bar %} | ||
6 | |||
7 | {{ foo('foo') }} | ||
8 | {{ foobar('foo') }} | ||
9 | {{ bar('foo') }} | ||
10 | --TEMPLATE(forms.twig)-- | ||
11 | {% macro foo(name) %}foo{{ name }}{% endmacro %} | ||
12 | {% macro bar(name) %}bar{{ name }}{% endmacro %} | ||
13 | --DATA-- | ||
14 | return array() | ||
15 | --EXPECT-- | ||
16 | foofoo | ||
17 | foofoo | ||
18 | barfoo | ||