From 51c866f415bbee670cd9ba13591307bce8dabdca Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Sat, 28 Jul 2012 10:32:10 +0200 Subject: [PATCH] added a test to verify that the merge filter actually behaves like said in the documentation (closes #789) --- test/Twig/Tests/Fixtures/filters/merge.test | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/test/Twig/Tests/Fixtures/filters/merge.test b/test/Twig/Tests/Fixtures/filters/merge.test index 357b352..2bd3d4c 100644 --- a/test/Twig/Tests/Fixtures/filters/merge.test +++ b/test/Twig/Tests/Fixtures/filters/merge.test @@ -5,10 +5,12 @@ {{ items|merge({'bar': 'foo'})|keys|join }} {{ {'bar': 'foo'}|merge(items)|join }} {{ {'bar': 'foo'}|merge(items)|keys|join }} +{{ numerics|merge([4, 5, 6])|join }} --DATA-- -return array('items' => array('foo' => 'bar')) +return array('items' => array('foo' => 'bar'), 'numerics' => array(1, 2, 3)) --EXPECT-- barfoo foobar foobar barfoo +123456 -- 1.7.2.5