Skip to content

Commit ce0a6a9

Browse files
OskarStarknicolas-grekas
authored andcommitted
Migrate to static data providers using rector/rector
1 parent 31722be commit ce0a6a9

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

Test/TranslatorTest.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -117,15 +117,15 @@ public function testGetLocaleReturnsDefaultLocaleIfNotSet()
117117
$this->assertEquals('en', $translator->getLocale());
118118
}
119119

120-
public function getTransTests()
120+
public static function getTransTests()
121121
{
122122
return [
123123
['Symfony is great!', 'Symfony is great!', []],
124124
['Symfony is awesome!', 'Symfony is %what%!', ['%what%' => 'awesome']],
125125
];
126126
}
127127

128-
public function getTransChoiceTests()
128+
public static function getTransChoiceTests()
129129
{
130130
return [
131131
['There are no apples', '{0} There are no apples|{1} There is one apple|]1,Inf] There are %count% apples', 0],
@@ -149,7 +149,7 @@ public function testInterval($expected, $number, $interval)
149149
$this->assertEquals($expected, $translator->trans($interval.' foo|[1,Inf[ bar', ['%count%' => $number]));
150150
}
151151

152-
public function getInterval()
152+
public static function getInterval()
153153
{
154154
return [
155155
['foo', 3, '{1,2, 3 ,4}'],
@@ -192,7 +192,7 @@ public function testThrowExceptionIfMatchingMessageCannotBeFound($id, $number)
192192
$translator->trans($id, ['%count%' => $number]);
193193
}
194194

195-
public function getNonMatchingMessages()
195+
public static function getNonMatchingMessages()
196196
{
197197
return [
198198
['{0} There are no apples|{1} There is one apple', 2],
@@ -202,7 +202,7 @@ public function getNonMatchingMessages()
202202
];
203203
}
204204

205-
public function getChooseTests()
205+
public static function getChooseTests()
206206
{
207207
return [
208208
['There are no apples', '{0} There are no apples|{1} There is one apple|]1,Inf] There are %count% apples', 0],
@@ -320,7 +320,7 @@ public function testLangcodes($nplural, $langCodes)
320320
*
321321
* @return array
322322
*/
323-
public function successLangcodes()
323+
public static function successLangcodes()
324324
{
325325
return [
326326
['1', ['ay', 'bo', 'cgg', 'dz', 'id', 'ja', 'jbo', 'ka', 'kk', 'km', 'ko', 'ky']],
@@ -339,7 +339,7 @@ public function successLangcodes()
339339
*
340340
* @return array with nplural together with langcodes
341341
*/
342-
public function failingLangcodes()
342+
public static function failingLangcodes()
343343
{
344344
return [
345345
['1', ['fa']],

0 commit comments

Comments
 (0)