Skip to content

Commit 8fa5863

Browse files
authored
Merge pull request #937 from Roave/renovate/squizlabs-php_codesniffer-4.x
Update dependency squizlabs/php_codesniffer to v4
2 parents 7fb2337 + 5ea442e commit 8fa5863

File tree

11 files changed

+51
-58
lines changed

11 files changed

+51
-58
lines changed

bin/roave-backward-compatibility-check.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -324,10 +324,9 @@ static function (string $installationPath) use ($composerIo): Installer {
324324
$application->add($apiCompareCommand);
325325
$application->setDefaultCommand('roave-backwards-compatibility-check:assert-backwards-compatible');
326326

327-
// @codingStandardsIgnoreStart
328327
$output->getErrorOutput()
329328
->writeln(
330-
<<<'MARKDOWN'
329+
<<<'MARKDOWN'
331330
## 🇷🇺 Российским гражданам
332331
333332
В Украине сейчас идет война. Силами РФ наносятся удары по гражданской инфраструктуре в [Харькове][1], [Киеве][2], [Чернигове][3], [Сумах][4], [Ирпене][5] и десятках других городов. Гибнут люди - и гражданское население, и военные, в том числе российские призывники, которых бросили воевать. Чтобы лишить собственный народ доступа к информации, правительство РФ запретило называть войну войной, закрыло независимые СМИ и принимает сейчас ряд диктаторских законов. Эти законы призваны заткнуть рот всем, кто против войны. За обычный призыв к миру сейчас можно получить несколько лет тюрьмы.
@@ -353,9 +352,8 @@ static function (string $installationPath) use ($composerIo): Installer {
353352
<fg=#0057b7>#StandWith</><fg=#ffd700>Ukraine</>
354353

355354

356-
MARKDOWN
355+
MARKDOWN,
357356
);
358-
// @codingStandardsIgnoreEnd
359357

360358
$application->run($input, $output);
361359
})();

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,14 @@
2727
}
2828
],
2929
"require-dev": {
30-
"doctrine/coding-standard": "^12.0.0",
30+
"doctrine/coding-standard": "^14.0.0",
3131
"justinrainbow/json-schema": "^6.6.0",
3232
"php-standard-library/psalm-plugin": "^2.3.0",
3333
"phpunit/phpunit": "^12.4.1",
3434
"psalm/plugin-phpunit": "^0.19.5",
3535
"roave/infection-static-analysis-plugin": "^1.39.0",
3636
"roave/security-advisories": "dev-master",
37-
"squizlabs/php_codesniffer": "^3.13.4",
37+
"squizlabs/php_codesniffer": "^4.0.0",
3838
"vimeo/psalm": "^6.13.1"
3939
},
4040
"conflict": {

composer.lock

Lines changed: 27 additions & 32 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/Change.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@
1010
/** @psalm-immutable */
1111
final class Change
1212
{
13-
private const ADDED = 'added';
14-
private const CHANGED = 'changed';
15-
private const REMOVED = 'removed';
16-
private const SKIPPED = 'skipped';
13+
private const string ADDED = 'added';
14+
private const string CHANGED = 'changed';
15+
private const string REMOVED = 'removed';
16+
private const string SKIPPED = 'skipped';
1717

1818
/** @psalm-param self::* $modificationType */
1919
private function __construct(

src/Configuration/ParseXmlConfigurationFile.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@
1616
/** @internal */
1717
final class ParseXmlConfigurationFile implements ParseConfigurationFile
1818
{
19-
private const CONFIGURATION_FILENAME = '.roave-backward-compatibility-check.xml';
19+
private const string CONFIGURATION_FILENAME = '.roave-backward-compatibility-check.xml';
2020

21-
private const SCHEMA = __DIR__ . '/../../Resources/schema.xsd';
21+
private const string SCHEMA = __DIR__ . '/../../Resources/schema.xsd';
2222

2323
public function parse(string $currentDirectory): Configuration
2424
{

src/DetectChanges/BCBreak/ClassConstantBased/ClassConstantVisibilityReduced.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@
1111

1212
final class ClassConstantVisibilityReduced implements ClassConstantBased
1313
{
14-
private const VISIBILITY_PRIVATE = 'private';
14+
private const string VISIBILITY_PRIVATE = 'private';
1515

16-
private const VISIBILITY_PROTECTED = 'protected';
16+
private const string VISIBILITY_PROTECTED = 'protected';
1717

18-
private const VISIBILITY_PUBLIC = 'public';
18+
private const string VISIBILITY_PUBLIC = 'public';
1919

2020
public function __invoke(ReflectionClassConstant $fromConstant, ReflectionClassConstant $toConstant): Changes
2121
{

src/DetectChanges/BCBreak/FunctionBased/ParameterNameChanged.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
*/
2525
final class ParameterNameChanged implements FunctionBased
2626
{
27-
private const NO_NAMED_ARGUMENTS_ANNOTATION = '@no-named-arguments';
27+
private const string NO_NAMED_ARGUMENTS_ANNOTATION = '@no-named-arguments';
2828

2929
private FunctionName $formatFunction;
3030

src/DetectChanges/BCBreak/MethodBased/MethodVisibilityReduced.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@
1111

1212
final class MethodVisibilityReduced implements MethodBased
1313
{
14-
private const VISIBILITY_PRIVATE = 'private';
14+
private const string VISIBILITY_PRIVATE = 'private';
1515

16-
private const VISIBILITY_PROTECTED = 'protected';
16+
private const string VISIBILITY_PROTECTED = 'protected';
1717

18-
private const VISIBILITY_PUBLIC = 'public';
18+
private const string VISIBILITY_PUBLIC = 'public';
1919

2020
public function __invoke(ReflectionMethod $fromMethod, ReflectionMethod $toMethod): Changes
2121
{

src/DetectChanges/BCBreak/PropertyBased/PropertyVisibilityReduced.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ public function __construct()
1919
$this->formatProperty = new ReflectionPropertyName();
2020
}
2121

22-
private const VISIBILITY_PRIVATE = 'private';
22+
private const string VISIBILITY_PRIVATE = 'private';
2323

24-
private const VISIBILITY_PROTECTED = 'protected';
24+
private const string VISIBILITY_PROTECTED = 'protected';
2525

26-
private const VISIBILITY_PUBLIC = 'public';
26+
private const string VISIBILITY_PUBLIC = 'public';
2727

2828
public function __invoke(ReflectionProperty $fromProperty, ReflectionProperty $toProperty): Changes
2929
{

test/e2e/Command/AssertBackwardsCompatibleTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
#[CoversNothing]
1616
final class AssertBackwardsCompatibleTest extends TestCase
1717
{
18-
private const COMPOSER_MANIFEST = <<<'JSON'
18+
private const string COMPOSER_MANIFEST = <<<'JSON'
1919
{
2020
"autoload": {
2121
"classmap": [
@@ -31,7 +31,7 @@ final class AssertBackwardsCompatibleTest extends TestCase
3131

3232
JSON;
3333

34-
private const BASELINE_CONFIGURATION = <<<'XML'
34+
private const string BASELINE_CONFIGURATION = <<<'XML'
3535
<?xml version="1.0" encoding="UTF-8" ?>
3636
<roave-bc-check>
3737
<baseline>
@@ -40,7 +40,7 @@ final class AssertBackwardsCompatibleTest extends TestCase
4040
</roave-bc-check>
4141
XML;
4242

43-
private const CLASS_VERSIONS = [
43+
private const array CLASS_VERSIONS = [
4444
<<<'PHP'
4545
<?php
4646

0 commit comments

Comments
 (0)