Yaffs site version 1.1
[yaffs-website] / vendor / twig / twig / test / Twig / Tests / Fixtures / tests / defined_for_blocks_with_template.test
1 --TEST--
2 "defined" support for blocks with a template argument
3 --TEMPLATE--
4 {{ block('foo', 'included.twig') is defined ? 'ok' : 'ko' }}
5 {{ block('foo', included_loaded) is defined ? 'ok' : 'ko' }}
6 {{ block('foo', included_loaded_internal) is defined ? 'ok' : 'ko' }}
7 --TEMPLATE(included.twig)--
8 {% block foo %}FOO{% endblock %}
9 --DATA--
10 return array(
11     'included_loaded' => $twig->load('included.twig'),
12     'included_loaded_internal' => $twig->loadTemplate('included.twig'),
13 )
14 --EXPECT--
15 ok
16 ok
17 ok