8000 Executed rector · symfony/symfony@0609d48 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0609d48

Browse files
committed
Executed rector
1 parent b48c5d8 commit 0609d48

File tree

611 files changed

+1322
-1322
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

611 files changed

+1322
-1322
lines changed

src/Symfony/Bridge/Doctrine/Tests/DataCollector/DoctrineDataCollectorTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ public function testSerialization($param, array $types, $expected)
134134
$this->assertTrue($collectedQueries['default'][0]['runnable']);
135135
}
136136

137-
public function paramProvider(): array
137+
public static function paramProvider(): array
138138
{
139139
return [
140140
['some value', [], 'some value'],

src/Symfony/Bridge/Doctrine/Tests/DataCollector/DoctrineDataCollectorWithDebugStackTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ public function testSerialization($param, array $types, $expected, $explainable,
107107
$this->assertSame($runnable, $collectedQueries['default'][0]['runnable']);
108108
}
109109

110-
public function paramProvider(): array
110+
public static function paramProvider(): array
111111
{
112112
return [
113113
['some value', [], 'some value', true],

src/Symfony/Bridge/Doctrine/Tests/DependencyInjection/DoctrineExtensionTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ public function testFixManagersAutoMappingsWithTwoAutomappings()
8484
$method->invoke($this->extension, $emConfigs, $bundles);
8585
}
8686

87-
public function getAutomappingData()
87+
public static function getAutomappingData()
8888
{
8989
return [
9090
[
@@ -197,7 +197,7 @@ public function testMappingTypeDetection()
197197
$this->assertSame($mappingType, \PHP_VERSION_ID < 80000 ? 'annotation' : 'attribute');
198198
}
199199

200-
public function providerBasicDrivers()
200+
public static function providerBasicDrivers()
201201
{
202202
return [
203203
['doctrine.orm.cache.apc.class', ['type' => 'apc']],
@@ -276,7 +276,7 @@ public function testUnrecognizedCacheDriverException()
276276
$this->invokeLoadCacheDriver($objectManager, $container, $cacheName);
277277
}
278278

279-
public function providerBundles()
279+
public static function providerBundles()
280280
{
281281
yield ['AnnotationsBundle', 'annotation', '/Entity'];
282282
yield ['FullEmbeddableAnnotationsBundle', 'annotation', '/Entity'];

src/Symfony/Bridge/Doctrine/Tests/Form/ChoiceList/ORMQueryBuilderLoaderTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,15 +262,15 @@ public function testEmbeddedIdentifierName()
262262
$loader->getEntitiesByIds('id.value', [1, '', 2, 3, 'foo']);
263263
}
264264

265-
public function provideGuidEntityClasses()
265+
public static function provideGuidEntityClasses()
266266
{
267267
return [
268268
['Symfony\Bridge\Doctrine\Tests\Fixtures\GuidIdEntity'],
269269
['Symfony\Bridge\Doctrine\Tests\Fixtures\UuidIdEntity'],
270270
];
271271
}
272272

273-
public function provideUidEntityClasses()
273+
public static function provideUidEntityClasses()
274274
{
275275
return [
276276
['Symfony\Bridge\Doctrine\Tests\Fixtures\UuidIdEntity'],

src/Symfony/Bridge/Doctrine/Tests/Form/DoctrineOrmTypeGuesserTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public function testTypeGuesser(string $type, $expected)
3535
$this->assertEquals($expected, $this->getGuesser($classMetadata)->guessType('TestEntity', 'field'));
3636
}
3737

38-
public function requiredType()
38+
public static function requiredType()
3939
{
4040
yield [Types::DATE_IMMUTABLE, new TypeGuess('Symfony\Component\Form\Extension\Core\Type\DateType', ['input' => 'datetime_immutable'], Guess::HIGH_CONFIDENCE)];
4141
yield [Types::DATE_MUTABLE, new TypeGuess('Symfony\Component\Form\Extension\Core\Type\DateType', [], Guess::HIGH_CONFIDENCE)];
@@ -57,7 +57,7 @@ public function testRequiredGuesser($classMetadata, $expected)
5757
$this->assertEquals($expected, $this->getGuesser($classMetadata)->guessRequired('TestEntity', 'field'));
5858
}
5959

60-
public function requiredProvider()
60+
public static function requiredProvider()
6161
{
6262
$return = [];
6363

src/Symfony/Bridge/Doctrine/Tests/Form/Type/EntityTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ public function testChoiceTranslationDomainIsDisabledByDefault($expanded)
158158
}
159159
}
160160

161-
public function choiceTranslationDomainProvider()
161+
public static function choiceTranslationDomainProvider()
162162
{
163163
return [
164164
[false],

src/Symfony/Bridge/Doctrine/Tests/Logger/DbalLoggerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public function testLog($sql, $params, $logParams)
4343
$dbalLogger->startQuery($sql, $params);
4444
}
4545

46-
public function getLogFixtures()
46+
public static function getLogFixtures()
4747
{
4848
return [
4949
['SQL', null, []],

src/Symfony/Bridge/Doctrine/Tests/Middleware/Debug/MiddlewareTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ private function getResourceFromString(string $str)
7979
return $res;
8080
}
8181

82-
public function provideExecuteMethod(): array
82+
public static function provideExecuteMethod(): array
8383
{
8484
return [
8585
'executeStatement' => [
@@ -173,7 +173,7 @@ public function testWithParamBound(callable $executeMethod)
173173
$this->assertGreaterThan(0, $debug[1]['executionMS']);
174174
}
175175

176-
public function provideEndTransactionMethod(): array
176+
public static function provideEndTransactionMethod(): array
177177
{
178178
return [
179179
'commit' => [
@@ -223,7 +223,7 @@ public function testTransaction(callable $endTransactionMethod, string $expected
223223
$this->assertGreaterThan(0, $debug[6]['executionMS']);
224224
}
225225

226-
public function provideExecuteAndEndTransactionMethods(): array
226+
public static function provideExecuteAndEndTransactionMethods(): array
227227
{
228228
return [
229229
'commit and exec' => [

src/Symfony/Bridge/Doctrine/Tests/PropertyInfo/DoctrineExtractorTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ public function testExtractEnum()
143143
$this->assertNull($this->createExtractor()->getTypes(DoctrineEnum::class, 'enumCustom', []));
144144
}
145145

146-
public function typesProvider()
146+
public static function typesProvider()
147147
{
148148
$provider = [
149149
['id', [new Type(Type::BUILTIN_TYPE_INT)]],

src/Symfony/Bridge/Doctrine/Tests/Types/UlidTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ public function testGetGuidTypeDeclarationSQL(AbstractPlatform $platform, string
140140
$this->assertEquals($expectedDeclaration, $this->type->getSqlDeclaration(['length' => 36], $platform));
141141
}
142142

143-
public function provideSqlDeclarations(): array
143+
public static function provideSqlDeclarations(): array
144144
{
145145
return [
146146
[new PostgreSQLPlatform(), 'UUID'],

src/Symfony/Bridge/Doctrine/Tests/Types/UuidTypeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ public function testGetGuidTypeDeclarationSQL(AbstractPlatform $platform, string
152152
$this->assertEquals($expectedDeclaration, $this->type->getSqlDeclaration(['length' => 36], $platform));
153153
}
154154

155-
public function provideSqlDeclarations(): array
155+
public static function provideSqlDeclarations(): array
156156
{
157157
return [
158158
[new PostgreSQLPlatform(), 'UUID'],

src/Symfony/Bridge/Doctrine/Tests/Validator/Constraints/UniqueEntityValidatorTest.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ public function testValidateUniqueness(UniqueEntity $constraint)
186186
->assertRaised();
187187
}
188188

189-
public function provideUniquenessConstraints(): iterable
189+
public static function provideUniquenessConstraints(): iterable
190190
{
191191
yield 'Doctrine style' => [new UniqueEntity([
192192
'message' => 'myMessage',
@@ -221,7 +221,7 @@ public function testValidateCustomErrorPath(UniqueEntity $constraint)
221221
->assertRaised();
222222
}
223223

224-
public function provideConstraintsWithCustomErrorPath(): iterable
224+
public static function provideConstraintsWithCustomErrorPath(): iterable
225225
{
226226
yield 'Doctrine style' => [new UniqueEntity([
227227
'message' => 'myMessage',
@@ -282,7 +282,7 @@ public function testValidateUniquenessWithIgnoreNullDisabled(UniqueEntity $const
282282
->assertRaised();
283283
}
284284

285-
public function provideConstraintsWithIgnoreNullDisabled(): iterable
285+
public static function provideConstraintsWithIgnoreNullDisabled(): iterable
286286
{
287287
yield 'Doctrine style' => [new UniqueEntity([
288288
'message' => 'myMessage',
@@ -331,7 +331,7 @@ public function testNoValidationIfFirstFieldIsNullAndNullValuesAreIgnored(Unique
331331
$this->assertNoViolation();
332332
}
333333

334-
public function provideConstraintsWithIgnoreNullEnabled(): iterable
334+
public static function provideConstraintsWithIgnoreNullEnabled(): iterable
335335
{
336336
yield 'Doctrine style' => [new UniqueEntity([
337337
'message' => 'myMessage',
@@ -432,7 +432,7 @@ function () use ($entity) {
432432
$this->assertNoViolation();
433433
}
434434

435-
public function provideConstraintsWithCustomRepositoryMethod(): iterable
435+
public static function provideConstraintsWithCustomRepositoryMethod(): iterable
436436
{
437437
yield 'Doctrine style' => [new UniqueEntity([
438438
'message' => 'myMessage',
@@ -473,7 +473,7 @@ public function testValidateResultTypes($entity1, $result)
473473
$this->assertNoViolation();
474474
}
475475

476-
public function resultTypesProvider()
476+
public static function resultTypesProvider()
477477
{
478478
$entity = new SingleIntIdEntity(1, 'foo');
479479

@@ -886,7 +886,7 @@ public function testValueCanBeNull()
886886
$this->assertNoViolation();
887887
}
888888

889-
public function resultWithEmptyIterator(): array
889+
public static function resultWithEmptyIterator(): array
890890
{
891891
$entity = new SingleIntIdEntity(1, 'foo');
892892

src/Symfony/Bridge/Doctrine/Tests/Validator/DoctrineLoaderTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ public function testClassValidator(bool $expected, string $classValidatorRegexp
209209
$this->assertSame($expected, $doctrineLoader->loadClassMetadata($classMetadata));
210210
}
211211

212-
public function regexpProvider()
212+
public static function regexpProvider()
213213
{
214214
return [
215215
[false, null],

src/Symfony/Bridge/Monolog/Tests/Formatter/ConsoleFormatterTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ public function testFormat(array $record, $expectedMessage)
2626
self::assertSame($expectedMessage, $formatter->format($record));
2727
}
2828

29-
public function providerFormatTests(): array
29+
public static function providerFormatTests(): array
3030
{
3131
$currentDateTime = new \DateTime();
3232

src/Symfony/Bridge/Monolog/Tests/Handler/ConsoleHandlerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ public function testVerbosityMapping($verbosity, $level, $isHandling, array $map
8989
$this->assertFalse($handler->handle($infoRecord), 'The handler finished handling the log.');
9090
}
9191

92-
public function provideVerbosityMappingTests()
92+
public static function provideVerbosityMappingTests()
9393
{
9494
return [
9595
[OutputInterface::VERBOSITY_QUIET, Logger::ERROR, true],

src/Symfony/Bridge/Monolog/Tests/Handler/FingersCrossed/HttpCodeActivationStrategyTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ public function testIsActivated($url, $record, $expected)
9797
self::assertEquals($expected, $strategy->isHandlerActivated($record));
9898
}
9999

100-
public function isActivatedProvider(): array
100+
public static function isActivatedProvider(): array
101101
{
102102
return [
103103
['/test', ['level' => Logger::ERROR], true],

src/Symfony/Bridge/Monolog/Tests/Handler/FingersCrossed/NotFoundActivationStrategyTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public function testIsActivated(string $url, array $record, bool $expected)
4949
self::assertEquals($expected, $strategy->isHandlerActivated($record));
5050
}
5151

52-
public function isActivatedProvider(): array
52+
public static function isActivatedProvider(): array
5353
{
5454
return [
5555
['/test', ['level' => Logger::DEBUG], false],

src/Symfony/Bridge/Monolog/Tests/Processor/DebugProcessorTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public function testDatetimeFormat(array $record, $expectedTimestamp)
3232
self::assertSame($expectedTimestamp, $records[0]['timestamp']);
3333
}
3434

35-
public function providerDatetimeFormatTests(): array
35+
public static function providerDatetimeFormatTests(): array
3636
{
3737
$record = self::getRecord();
3838

@@ -56,7 +56,7 @@ public function testDatetimeRfc3339Format(array $record, $expectedTimestamp)
5656
self::assertSame($expectedTimestamp, $records[0]['timestamp_rfc3339']);
5757
}
5858

59-
public function providerDatetimeRfc3339FormatTests(): array
59+
public static function providerDatetimeRfc3339FormatTests(): array
6060
{
6161
$record = self::getRecord();
6262

src/Symfony/Bridge/PhpUnit/Tests/DeprecationErrorHandler/ConfigurationTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ public function testItCanTellWhetherToDisplayAStackTrace()
179179
$this->assertTrue($configuration->shouldDisplayStackTrace('interesting'));
180180
}
181181

182-
public function provideItCanBeDisabled(): array
182+
public static function provideItCanBeDisabled(): array
183183
{
184184
return [
185185
['disabled', false],

src/Symfony/Bridge/PhpUnit/Tests/DeprecationErrorHandler/DeprecationTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ public function testItMutesOnlySpecificErrorMessagesWhenTheCallingCodeIsInPhpuni
9797
$this->assertSame($muted, $deprecation->isMuted());
9898
}
9999

100-
public function mutedProvider()
100+
public static function mutedProvider()
101101
{
102102
yield 'not from phpunit, and not a whitelisted message' => [
103103
false,
@@ -147,7 +147,7 @@ public function testItTakesMutesDeprecationFromPhpUnitFiles()
147147
$this->assertTrue($deprecation->isMuted());
148148
}
149149

150-
public function providerGetTypeDetectsSelf()
150+
public static function providerGetTypeDetectsSelf()
151151
{
152152
return [
153153
'not_from_vendors_file' => [Deprecation::TYPE_SELF, '', 'MyClass1', __FILE__],
@@ -182,7 +182,7 @@ public function testGetTypeDetectsSelf(string $expectedType, string $message, st
182182
$this->assertSame($expectedType, $deprecation->getType());
183183
}
184184

185-
public function providerGetTypeUsesRightTrace()
185+
public static function providerGetTypeUsesRightTrace()
186186
{
187187
$vendorDir = self::getVendorDir();
188188
$fakeTrace = [

src/Symfony/Bridge/ProxyManager/Tests/LazyProxy/PhpDumper/ProxyDumperTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ public function testCorrectAssigning(Definition $definition, $access)
9393
$this->assertStringMatchesFormat('%A$this->'.$access.'[\'foo\'] = %A', $code);
9494
}
9595

96-
public function getPrivatePublicDefinitions()
96+
public static function getPrivatePublicDefinitions()
9797
{
9898
return [
9999
[
@@ -164,7 +164,7 @@ protected function createProxy(\$class, \Closure \$factory)
164164
$this->assertSame(123, @$foo->dynamicProp);
165165
}
166166

167-
public function getProxyCandidates(): array
167+
public static function getProxyCandidates(): array
168168
{
169169
$definitions = [
170170
[new Definition(__CLASS__), true],

src/Symfony/Bridge/Twig/Tests/AppVariableTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public function testDebug($debugFlag)
4343
$this->assertEquals($debugFlag, $this->appVariable->getDebug());
4444
}
4545

46-
public function debugDataProvider()
46+
public static function debugDataProvider()
4747
{
4848
return [
4949
'debug on' => [true],

src/Symfony/Bridge/Twig/Tests/Command/DebugCommandTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ public function testDebugTemplateName(array $input, string $output, array $paths
8484
$this->assertStringMatchesFormat($output, $tester->getDisplay(true));
8585
}
8686

87-
public function getDebugTemplateNameTestData()
87+
public static function getDebugTemplateNameTestData()
8888
{
8989
$defaultPaths = [
9090
'templates/' => null,
@@ -315,7 +315,7 @@ public function testComplete(array $input, array $expectedSuggestions)
315315
$this->assertSame($expectedSuggestions, $suggestions);
316316
}
317317

318-
public function provideCompletionSuggestions(): iterable
318+
public static function provideCompletionSuggestions(): iterable
319319
{
320320
yield 'name' => [['email'], []];
321321
yield 'option --format' => [['--format', ''], ['text', 'json']];

src/Symfony/Bridge/Twig/Tests/Command/LintCommandTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ public function testComplete(array $input, array $expectedSuggestions)
150150
$this->assertSame($expectedSuggestions, $tester->complete($input));
151151
}
152152

153-
public function provideCompletionSuggestions()
153+
public static function provideCompletionSuggestions()
154154
{
155155
yield 'option' => [['--format', ''], ['txt', 'json', 'github']];
156156
}

src/Symfony/Bridge/Twig/Tests/Extension/CodeExtensionTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,15 +44,15 @@ public function testGettingMethodAbbreviation($method, $abbr)
4444
$this->assertEquals($this->getExtension()->abbrMethod($method), $abbr);
4545
}
4646

47-
public function getClassNameProvider(): array
47+
public static function getClassNameProvider(): array
4848
{
4949
return [
5050
['F\Q\N\Foo', '<abbr title="F\Q\N\Foo">Foo</abbr>'],
5151
['Bare', '<abbr title="Bare">Bare</abbr>'],
5252
];
5353
}
5454

55-
public function getMethodNameProvider(): array
55+
public static function getMethodNameProvider(): array
5656
{
5757
return [
5858
['F\Q\N\Foo::Method', '<abbr title="F\Q\N\Foo">Foo</abbr>::Method()'],

0 commit comments

Comments
 (0)
0