Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
added some more unit tests
  • Loading branch information
fabpot committed Jan 25, 2015
1 parent 89afc0d commit e7c5bde
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 3 deletions.
Expand Up @@ -4,10 +4,15 @@ Exception for multiline array with undefined variable
{% set foo = {
foo: 'foo',
bar: 'bar',


foobar: foobar,
foo2: 'foo2'



foo2: foo2,
} %}
--DATA--
return array()
return array('foobar' => 'foobar')
--EXCEPTION--
Twig_Error_Runtime: Variable "foobar" does not exist in "index.twig" at line 5
Twig_Error_Runtime: Variable "foo2" does not exist in "index.twig" at line 11
@@ -0,0 +1,18 @@
--TEST--
Exception for multiline array with undefined variable
--TEMPLATE--
{% set foo = {
foo: 'foo',
bar: 'bar',


foobar: foobar,



foo2: foo2,
} %}
--DATA--
return array()
--EXCEPTION--
Twig_Error_Runtime: Variable "foobar" does not exist in "index.twig" at line 7

0 comments on commit e7c5bde

Please sign in to comment.