From: Joseph Bielawski Date: Wed, 27 Apr 2011 15:01:08 +0000 (-0700) Subject: Additional tests for issue #307 X-Git-Url: http://git.silmor.de/gitweb/?a=commitdiff_plain;h=db50167f5ffb284aca54aa4af1e92ea3cc3b02d7;p=web%2Fkonrad%2Ftwig.git Additional tests for issue #307 --- diff --git a/test/Twig/Tests/Fixtures/tests/empty.test b/test/Twig/Tests/Fixtures/tests/empty.test index d183a93..06065f0 100644 --- a/test/Twig/Tests/Fixtures/tests/empty.test +++ b/test/Twig/Tests/Fixtures/tests/empty.test @@ -4,9 +4,15 @@ {{ foo is empty ? 'ok' : 'ko' }} {{ bar is empty ? 'ok' : 'ko' }} {{ foobar is empty ? 'ok' : 'ko' }} +{{ array is empty ? 'ok' : 'ko' }} +{{ zero is empty ? 'ok' : 'ko' }} +{{ string is empty ? 'ok' : 'ko' }} --DATA-- -return array('foo' => '', 'bar' => null, 'foobar' => false); +return array('foo' => '', 'bar' => null, 'foobar' => false, 'array' => array(), 'zero' => 0, 'string' => '0'); --EXPECT-- ok ok ok +ok +ko +ko \ No newline at end of file