Skip to content

Commit d5c5d63

Browse files
Merge branch '3.3' into 3.4
* 3.3: PHP CS Fixer: clean up repo and adjust config use interface_exists instead of class_exists Dumper shouldn't use html format for phpdbg [Validator] Fix access to root object when using composite constraint
2 parents 363fcaa + c4f577a commit d5c5d63

File tree

1 file changed

+29
-12
lines changed

1 file changed

+29
-12
lines changed

Tests/Extension/TranslationExtensionTest.php

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -88,18 +88,35 @@ public function getTransTests()
8888
array('{% trans into "fr"%}Hello{% endtrans %}', 'Hello'),
8989

9090
// transchoice
91-
array('{% transchoice count from "messages" %}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples{% endtranschoice %}',
92-
'There is no apples', array('count' => 0)),
93-
array('{% transchoice count %}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples{% endtranschoice %}',
94-
'There is 5 apples', array('count' => 5)),
95-
array('{% transchoice count %}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples (%name%){% endtranschoice %}',
96-
'There is 5 apples (Symfony)', array('count' => 5, 'name' => 'Symfony')),
97-
array('{% transchoice count with { \'%name%\': \'Symfony\' } %}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples (%name%){% endtranschoice %}',
98-
'There is 5 apples (Symfony)', array('count' => 5)),
99-
array('{% transchoice count into "fr"%}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples{% endtranschoice %}',
100-
'There is no apples', array('count' => 0)),
101-
array('{% transchoice 5 into "fr"%}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples{% endtranschoice %}',
102-
'There is 5 apples'),
91+
array(
92+
'{% transchoice count from "messages" %}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples{% endtranschoice %}',
93+
'There is no apples',
94+
array('count' => 0),
95+
),
96+
array(
97+
'{% transchoice count %}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples{% endtranschoice %}',
98+
'There is 5 apples',
99+
array('count' => 5),
100+
),
101+
array(
102+
'{% transchoice count %}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples (%name%){% endtranschoice %}',
103+
'There is 5 apples (Symfony)',
104+
array('count' => 5, 'name' => 'Symfony'),
105+
),
106+
array(
107+
'{% transchoice count with { \'%name%\': \'Symfony\' } %}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples (%name%){% endtranschoice %}',
108+
'There is 5 apples (Symfony)',
109+
array('count' => 5),
110+
),
111+
array(
112+
'{% transchoice count into "fr"%}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples{% endtranschoice %}',
113+
'There is no apples',
114+
array('count' => 0),
115+
),
116+
array(
117+
'{% transchoice 5 into "fr"%}{0} There is no apples|{1} There is one apple|]1,Inf] There is %count% apples{% endtranschoice %}',
118+
'There is 5 apples',
119+
),
103120

104121
// trans filter
105122
array('{{ "Hello"|trans }}', 'Hello'),

0 commit comments

Comments
 (0)