Skip to content

Commit 91eb363

Browse files
committed
NEXT-38488 - Update friendsofphp/php-cs-fixer to version 3.64.0
1 parent 3e50f43 commit 91eb363

File tree

13 files changed

+17
-16
lines changed

13 files changed

+17
-16
lines changed

.php-cs-fixer.dist.php

+1
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
'single_quote' => ['strings_containing_single_quote_chars' => true],
4747
'strict_comparison' => true,
4848
'strict_param' => true,
49+
'trailing_comma_in_multiline' => ['after_heredoc' => true, 'elements' => ['array_destructuring', 'arrays', 'match']],
4950
'void_return' => true,
5051
'yoda_style' => [
5152
'equal' => false,

composer.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,7 @@
167167
"brianium/paratest": "^7.3",
168168
"dominikb/composer-license-checker": "^2.5",
169169
"ergebnis/phpunit-slow-test-detector": "^2.4",
170+
"friendsofphp/php-cs-fixer": "3.64.0",
170171
"jdorn/sql-formatter": "^1.2.17",
171172
"league/construct-finder": "^1.1",
172173
"league/flysystem-async-aws-s3": "^3.10.3",
@@ -194,8 +195,7 @@
194195
"symfony/phpunit-bridge": "~7.1.1",
195196
"symfony/var-dumper": "~7.1.1",
196197
"symplify/phpstan-rules": "13.0.0",
197-
"tomasvotruba/type-coverage": "0.3.1",
198-
"friendsofphp/php-cs-fixer": "3.63.2"
198+
"tomasvotruba/type-coverage": "0.3.1"
199199
},
200200
"suggest": {
201201
"shopware/dev-tools": "For development tools, profiler, faker, etc",

src/Core/DevOps/Test/AnnotationTagTester.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ private function validateExperimentalVersion(string $propertiesString): void
155155
!isset($properties['stableVersion']) => throw new \InvalidArgumentException('Could not find property stableVersion in experimental annotation.'),
156156
!isset($properties['feature']) => throw new \InvalidArgumentException('Could not find property feature in experimental annotation.'),
157157
!preg_match('/^(?:[A-Z]+(_[A-Z]+)*)+$/', $properties['feature']) => throw new \InvalidArgumentException('The value of feature-property can not be empty, contain white spaces and must be in ALL_CAPS format.'),
158-
default => $this->validateAgainstPlatformVersion($properties['stableVersion'])
158+
default => $this->validateAgainstPlatformVersion($properties['stableVersion']),
159159
};
160160
}
161161

src/Core/Framework/Api/ApiDefinition/Generator/OpenApi/OpenApiSchemaBuilder.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ private function createInfo(string $api, string $version): Info
8282
8383
For a better overview, all CRUD-endpoints are hidden by default. If you want to show also CRUD-endpoints
8484
add the query parameter `type=jsonapi`.
85-
EOF
85+
EOF,
8686
]);
8787
}
8888

src/Core/Framework/Api/Sync/SyncFkResolver.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ private function collect(string $entity, array &$payload, string $pointer): arra
107107
$ref = match (true) {
108108
$field instanceof FkField => $field->getReferenceDefinition()->getEntityName(),
109109
$field instanceof IdField => $entity,
110-
default => null
110+
default => null,
111111
};
112112

113113
if ($ref === null) {

src/Core/Framework/DataAbstractionLayer/AttributeEntityCompiler.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ private function getFieldArgs(string $entity, OneToMany|ManyToMany|ManyToOne|One
241241
$field instanceof AutoIncrement, $field instanceof Version => [],
242242
$field instanceof ReferenceVersion => [$field->entity, $column],
243243
$field instanceof Serialized => [$column, $property->getName(), $field->serializer],
244-
default => [$column, $property->getName()]
244+
default => [$column, $property->getName()],
245245
};
246246
}
247247

@@ -316,7 +316,7 @@ private function getFlags(Field $field, \ReflectionProperty $property): array
316316
OnDelete::CASCADE => ['class' => CascadeDelete::class],
317317
OnDelete::SET_NULL => ['class' => SetNullOnDelete::class],
318318
OnDelete::RESTRICT => ['class' => RestrictDelete::class],
319-
default => null
319+
default => null,
320320
};
321321

322322
if ($flags['cascade'] === null) {

src/Core/Framework/Plugin/PluginZipDetector.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public function detect(string $zipFilePath): string
2727
return match (true) {
2828
$this->isPlugin($archive) => PluginManagementService::PLUGIN,
2929
$this->isApp($archive) => PluginManagementService::APP,
30-
default => throw PluginException::noPluginFoundInZip($zipFilePath)
30+
default => throw PluginException::noPluginFoundInZip($zipFilePath),
3131
};
3232
} finally {
3333
$archive->close();

src/Core/Service/ServiceSourceResolver.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ public function supports(Manifest|AppEntity $app): bool
5353
{
5454
return match (true) {
5555
$app instanceof AppEntity => $app->getSourceType() === $this->name(),
56-
$app instanceof Manifest => preg_match('#^https?://#', $app->getPath()) && $app->getMetadata()->isSelfManaged()
56+
$app instanceof Manifest => preg_match('#^https?://#', $app->getPath()) && $app->getMetadata()->isSelfManaged(),
5757
};
5858
}
5959

src/Elasticsearch/Product/CustomFieldUpdater.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ public static function getTypeFromCustomFieldType(string $type): array
8383
'type' => 'object',
8484
'dynamic' => true,
8585
],
86-
default => AbstractElasticsearchDefinition::KEYWORD_FIELD + AbstractElasticsearchDefinition::SEARCH_FIELD
86+
default => AbstractElasticsearchDefinition::KEYWORD_FIELD + AbstractElasticsearchDefinition::SEARCH_FIELD,
8787
};
8888
}
8989

tests/integration/Core/System/CustomEntity/Xml/Config/CmsAwareAndAdminUiTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ private function assertCmsAwareAndAdminUiIsInstalled(AppEntity|PluginEntity $ent
241241
$idColumn = match ($entity::class) {
242242
AppEntity::class => 'app_id',
243243
PluginEntity::class => 'plugin_id',
244-
default => throw new \Exception('Wrong Entity!')
244+
default => throw new \Exception('Wrong Entity!'),
245245
};
246246
$cmsAwareAndAdminUiSettings = $this->connection->executeQuery(
247247
"SELECT flags FROM custom_entity WHERE $idColumn = :id",

tests/unit/Core/Content/Product/Stock/OrderStockSubscriberTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ function (array $command) use ($orderItemDefinition, $idMapper) {
294294
[]
295295
),
296296
'/0'
297-
)
297+
),
298298
};
299299
},
300300
$commands

tests/unit/Core/Service/ServiceClientTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ public function testDownloadAppZipForVersion(): void
202202
2 => 'part2',
203203
3 => 'part3',
204204
4 => '',
205-
default => null
205+
default => null,
206206
};
207207

208208
static::assertSame('/some/file', $filename);

tests/unit/Storefront/Theme/ThemeCompilerTest.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ public static function configForDumpVariables(): \Generator
318318
\$sw-custom-media: '456';
319319
\$sw-asset-theme-url: 'http://localhost';
320320
321-
PHP_EOL
321+
PHP_EOL,
322322
];
323323

324324
yield 'ignores fields with scss config property set to false' => [
@@ -351,7 +351,7 @@ public static function configForDumpVariables(): \Generator
351351
\$sw-color-brand-secondary: #526e7f;
352352
\$sw-asset-theme-url: 'http://localhost';
353353
354-
PHP_EOL
354+
PHP_EOL,
355355
];
356356
yield 'HasNoConfigFieldsAndReturnsOnlyDefaultVariables' => [
357357
[
@@ -407,7 +407,7 @@ public static function configForDumpVariables(): \Generator
407407
\$sw-zero-margin: 0;
408408
\$sw-asset-theme-url: 'http://localhost';
409409
410-
PHP_EOL
410+
PHP_EOL,
411411
];
412412
}
413413

0 commit comments

Comments
 (0)