Skip to content

Commit 676ead3

Browse files
tools(deps-dev): Update friendsofphp/php-cs-fixer requirement from 3.59.3 to 3.64.0 in /tools/php-cs-fixer (#465)
Updates the requirements on [friendsofphp/php-cs-fixer](https://github.com/PHP-CS-Fixer/PHP-CS-Fixer) to permit the latest version. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/releases">friendsofphp/php-cs-fixer's releases</a>.</em></p> <blockquote> <h2>v3.64.0 Space Sets</h2> <h2>What's Changed</h2> <ul> <li>feat: Update PSR2, PSR12 and PER-CS2 with <code>single_space_after_...</code> config by <a href="https://github.com/SpacePossum"><code>@​SpacePossum</code></a> in <a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/pull/8171">PHP-CS-Fixer/PHP-CS-Fixer#8171</a></li> <li>feat: Symfony.trailing_comma_in_multiline - adjust configuration by <a href="https://github.com/keradus"><code>@​keradus</code></a> in <a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/pull/8161">PHP-CS-Fixer/PHP-CS-Fixer#8161</a></li> <li>feat: Symfony - adjust configuration for sets by <a href="https://github.com/keradus"><code>@​keradus</code></a> in <a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/pull/8188">PHP-CS-Fixer/PHP-CS-Fixer#8188</a></li> <li>CI: Update PHPStan to 1.12.0 and fix the error that appeared by <a href="https://github.com/kubawerlos"><code>@​kubawerlos</code></a> in <a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/pull/8184">PHP-CS-Fixer/PHP-CS-Fixer#8184</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/compare/v3.63.2...v3.64.0">https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/compare/v3.63.2...v3.64.0</a></p> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/blob/master/CHANGELOG.md">friendsofphp/php-cs-fixer's changelog</a>.</em></p> <blockquote> <h2>Changelog for v3.64.0</h2> <ul> <li>feat: Symfony - adjust configuration for sets (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8188">#8188</a>)</li> <li>feat: Symfony.trailing_comma_in_multiline - adjust configuration (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8161">#8161</a>)</li> <li>feat: Update PSR2, PSR12 and PER-CS2 with <code>single_space_around_construct</code> config (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8171">#8171</a>)</li> <li>CI: Update PHPStan to 1.12.0 and fix the error that appeared (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8184">#8184</a>)</li> </ul> <h2>Changelog for v3.63.2</h2> <ul> <li>fix: <code>FullyQualifiedStrictTypesFixer</code> - reset cache even if there is no <code>use</code> (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8183">#8183</a>)</li> </ul> <h2>Changelog for v3.63.1</h2> <ul> <li>dummy release</li> </ul> <h2>Changelog for v3.63.0</h2> <ul> <li>feat: Add <code>array_destructuring</code> as option for <code>trailing_comma_in_multiline</code> (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8172">#8172</a>)</li> <li>feat: remove braces even for single import (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8156">#8156</a>)</li> <li>feat: TrailingCommaInMultilineFixer - dynamically evaluate config against PHP version (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8167">#8167</a>)</li> <li>fix: Do not shorten FQN for class resolution if imported symbol is not a class (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/7705">#7705</a>)</li> <li>fix: Ensure PHP binary path is used as a single CLI argument in parallel worker process (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8180">#8180</a>)</li> <li>fix: <code>PhpUnitAttributesFixer</code> - fix priorities with <code>PhpUnitDataProvider(.+)Fixer</code> (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8169">#8169</a>)</li> <li>chore: add tags for data providers that will change PHPStan's baseline (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8178">#8178</a>)</li> <li>chore: add <code>@return</code> tags for data providers already having PHPDoc (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8176">#8176</a>)</li> <li>chore: add <code>@return</code> tags for data providers that do not have array in data (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8179">#8179</a>)</li> <li>chore: remove duplicates from data providers (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8164">#8164</a>)</li> <li>chore: remove duplicates from data providers that are copies in code (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8145">#8145</a>)</li> <li>chore: remove <code>beStrictAboutTodoAnnotatedTests</code> from PHPUnit's config (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8160">#8160</a>)</li> <li>CI: Update PHPStan to 1.11.10 (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8163">#8163</a>)</li> <li>CI: Update PHPStan to 1.11.11 and fix error that changed (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8174">#8174</a>)</li> <li>docs: fix indent on rule <code>date_time_create_from_format_call</code> (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8173">#8173</a>)</li> </ul> <h2>Changelog for v3.62.0</h2> <ul> <li>feat: set new_with_parentheses for anonymous_class to false in PER-CS2.0 (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8140">#8140</a>)</li> <li>chore: NewWithParenthesesFixer - create TODO to change the default configuration to match PER-CS2 (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8148">#8148</a>)</li> </ul> <h2>Changelog for v3.61.1</h2> <ul> <li>fix: <code>NoSuperfluousPhpdocTagsFixer</code> - fix &quot;Undefined array key 0&quot; error (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8150">#8150</a>)</li> </ul> <h2>Changelog for v3.61.0</h2> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/58dd9c931c785a79739310aef5178928305ffa67"><code>58dd9c9</code></a> prepared the 3.64.0 release</li> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/209f77687bd200f334cc658616857801ccaced37"><code>209f776</code></a> feat: Symfony - adjust configuration for sets (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8188">#8188</a>)</li> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/df2b6c2e3d2dc4c421a50364fe5419c4e6d67335"><code>df2b6c2</code></a> feat: Symfony.trailing_comma_in_multiline - adjust configuration (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8161">#8161</a>)</li> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/1e4b0f237b8465b52197aae26814e188178e3bfb"><code>1e4b0f2</code></a> feat: Update PSR2, PSR12 and PER-CS2 with <code>single_space_around_construct</code> con...</li> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/00634e16143d2a51c70ccdcf24b10f30093ab6ec"><code>00634e1</code></a> CI: Update PHPStan to 1.12.0 and fix the error that appeared (<a href="https://redirect.github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues/8184">#8184</a>)</li> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/970a9c55c95bb76024ee11ce098245cbb9c599d5"><code>970a9c5</code></a> bumped version</li> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/9d427f3f14984403a6ae9fc726b61765ca0c005e"><code>9d427f3</code></a> prepared the 3.63.2 release</li> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/5094b03d261b1b24475b2b41f25516d3653a879e"><code>5094b03</code></a> fix: <code>FullyQualifiedStrictTypesFixer</code> - reset cache even if there is no <code>use</code>...</li> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/2189cb5b0ee3944758d796b691db1bb1298f83a5"><code>2189cb5</code></a> bumped version</li> <li><a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/commit/ee3cc2e1fbfbddf98c17d4615db574a2a311c1ea"><code>ee3cc2e</code></a> prepared the 3.63.1 release</li> <li>Additional commits viewable in <a href="https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/compare/v3.59.3...v3.64.0">compare view</a></li> </ul> </details> <br /> Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> --------- Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: Jan Kowalleck <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jan Kowalleck <[email protected]>
1 parent 93dae90 commit 676ead3

File tree

15 files changed

+20
-15
lines changed

15 files changed

+20
-15
lines changed

HISTORY.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@ All notable changes to this project will be documented in this file.
66

77
<!-- add unreleased items here -->
88

9+
* Style
10+
* Applied latest PHP Coding Standards (via [#465])
11+
12+
[#465]: https://github.com/CycloneDX/cyclonedx-php-library/pull/465
13+
914
## 3.4.0 - 2024-05-06
1015

1116
* Changed

src/Core/Factories/LicenseFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class LicenseFactory
3535
{
3636
public function __construct(
3737
private readonly LicenseIdentifiers $licenseIdentifiers = new LicenseIdentifiers(),
38-
private readonly SpdxLicenses $spdxLicenses = new SpdxLicenses()
38+
private readonly SpdxLicenses $spdxLicenses = new SpdxLicenses(),
3939
) {
4040
}
4141

src/Core/Serialization/DOM/Normalizers/BomNormalizer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public function normalize(Bom $bom): DOMElement
4646
$document = $factory->getDocument();
4747

4848
$element = $document->createElementNS(
49-
sprintf(self::XML_NAMESPACE_PATTERN, $factory->getSpec()->getVersion()->value),
49+
\sprintf(self::XML_NAMESPACE_PATTERN, $factory->getSpec()->getVersion()->value),
5050
'bom' // no namespace = defaultNS - so children w/o NS fall under this NS
5151
);
5252
SimpleDOM::setAttributes(

src/Core/Serialization/DOM/_BaseNormalizer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
abstract class _BaseNormalizer
3535
{
3636
public function __construct(
37-
private readonly NormalizerFactory $normalizerFactory
37+
private readonly NormalizerFactory $normalizerFactory,
3838
) {
3939
}
4040

src/Core/Serialization/JSON/_BaseNormalizer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
abstract class _BaseNormalizer
3535
{
3636
public function __construct(
37-
private readonly NormalizerFactory $normalizerFactory
37+
private readonly NormalizerFactory $normalizerFactory,
3838
) {
3939
}
4040

src/Core/Serialization/JsonSerializer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ class JsonSerializer extends BaseSerializer
102102
*/
103103
public function __construct(
104104
protected readonly JSON\NormalizerFactory $normalizerFactory,
105-
int $jsonEncodeFlags = self::JsonEncodeFlagsDefaultOptions
105+
int $jsonEncodeFlags = self::JsonEncodeFlagsDefaultOptions,
106106
) {
107107
$this->jsonEncodeFlags = self::JsonEncodeFlagsDefaults
108108
| ($jsonEncodeFlags & self::JsonEncodeFlagsAllowedOptions);

src/Core/Serialization/XmlSerializer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ class XmlSerializer extends BaseSerializer
4141
public function __construct(
4242
protected readonly DOM\NormalizerFactory $normalizerFactory,
4343
protected readonly string $xmlVersion = '1.0',
44-
protected readonly string $xmlEncoding = 'UTF-8'
44+
protected readonly string $xmlEncoding = 'UTF-8',
4545
) {
4646
}
4747

src/Core/Utils/BomUtility.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ abstract class BomUtility
4242
*/
4343
public static function randomSerialNumber(): string
4444
{
45-
return sprintf(
45+
return \sprintf(
4646
'urn:uuid:%04x%04x-%04x-%04x-%04x-%04x%04x%04x',
4747
random_int(0, 0xFFFF),
4848
random_int(0, 0xFFFF),

src/Core/Validation/BaseValidator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ abstract class BaseValidator implements Validator
3232
{
3333
public function __construct(
3434
/* @TODO in next major version: use `\CycloneDX\Core\Enums\Version` instead of `Spec` */
35-
private readonly Spec $spec
35+
private readonly Spec $spec,
3636
) {
3737
}
3838

src/Core/Validation/ValidationError.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ class ValidationError
3636
protected ?object $error = null;
3737

3838
final protected function __construct(
39-
private readonly string $message
39+
private readonly string $message,
4040
) {
4141
}
4242

tests/Core/Collections/ComponentRepositoryTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ public function testFindItem(
7979
ComponentRepository $repo,
8080
string $findName,
8181
?string $findGroup,
82-
array $expectedFindings
82+
array $expectedFindings,
8383
): void {
8484
$actual = $repo->findItem($findName, $findGroup);
8585

tests/Core/Serialization/DOM/Normalizers/DependenciesNormalizerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ public function testNormalize(Bom $bom, array $expecteds): void
9595
self::assertCount(
9696
0,
9797
$missing,
98-
sprintf("missing:\n%s\nin:\n%s",
98+
\sprintf("missing:\n%s\nin:\n%s",
9999
print_r($missing, true),
100100
print_r($actuals, true),
101101
)

tests/Core/Serialization/JSON/Normalizers/DependenciesNormalizerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public function testNormalize(Bom $bom, array $expecteds): void
8686
self::assertCount(
8787
0,
8888
$missing,
89-
sprintf("missing:\n%s\nin:\n%s",
89+
\sprintf("missing:\n%s\nin:\n%s",
9090
print_r($missing, true),
9191
print_r($actuals, true),
9292
)

tools/php-cs-fixer/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"php": "^8.1"
77
},
88
"require-dev": {
9-
"friendsofphp/php-cs-fixer": "3.59.3",
9+
"friendsofphp/php-cs-fixer": "3.64.0",
1010
"roave/security-advisories": "dev-latest"
1111
},
1212
"prefer-stable": true,

tools/schema-downloader/download.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,8 @@ abstract class BomJsonStrict extends BaseDownloadable
122122
BomJsonStrict::class,
123123
] as $class) {
124124
foreach ($class::Versions as $version) {
125-
$source = sprintf($class::SourcePattern, $version);
126-
$target = sprintf($class::TargetPattern, $version);
125+
$source = \sprintf($class::SourcePattern, $version);
126+
$target = \sprintf($class::TargetPattern, $version);
127127

128128
$content = file_get_contents($source);
129129
$content = strtr($content, $class::ReplaceStr);

0 commit comments

Comments
 (0)