Skip to content

Commit d2d56dd

Browse files
committed
fix string class name, skip a rector rule on files
1 parent b2f33c8 commit d2d56dd

File tree

5 files changed

+18
-8
lines changed

5 files changed

+18
-8
lines changed

rector.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@
33
declare(strict_types=1);
44

55
use Rector\CodeQuality\Rector\Class_\InlineConstructorDefaultToPropertyRector;
6+
use Rector\CodingStyle\Rector\String_\UseClassKeywordForClassNameResolutionRector;
67
use Rector\Config\RectorConfig;
8+
use Rector\Php55\Rector\String_\StringClassNameToClassConstantRector;
79
use Rector\Set\ValueObject\LevelSetList;
810
use Rector\PHPUnit\Set\PHPUnitLevelSetList;
911
use Rector\Symfony\Set\SymfonyLevelSetList;
@@ -20,4 +22,13 @@
2022
PHPUnitLevelSetList::UP_TO_PHPUNIT_100,
2123
SymfonyLevelSetList::UP_TO_SYMFONY_60,
2224
]);
25+
26+
$rectorConfig->skip([StringClassNameToClassConstantRector::class => [
27+
__DIR__ . '/src/Plugin/Filtering/Builder/Drop.php',
28+
__DIR__ . '/src/Plugin/Filtering/Builder/Reject.php',
29+
__DIR__ . '/src/Plugin/SFTP/Builder/Extractor.php',
30+
__DIR__ . '/src/Plugin/SFTP/Builder/Loader.php',
31+
__DIR__ . '/src/Plugin/Batching/Builder/Fork.php',
32+
__DIR__ . '/src/Plugin/Batching/Builder/Merge.php',
33+
]]);
2334
};

src/Action/SFTP/Builder/Action.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public function withState(Node\Expr $state): self
3737
public function getNode(): Node
3838
{
3939
return new Node\Expr\New_(
40-
class: new Node\Name\FullyQualified('Kiboko\Component\Action\Flow\SFTP\UploadFile'),
40+
class: new Node\Name\FullyQualified('Kiboko\\Component\\Action\\Flow\\SFTP\\UploadFile'),
4141
args: [
4242
new Node\Arg(
4343
value: $this->host,

src/Builder/Workflow.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ public function addPipeline(string $code, string $pipelineFilename): self
2323
args: [
2424
new Node\Arg(
2525
new Node\Expr\StaticCall(
26-
new Node\Name\FullyQualified('Kiboko\Component\Workflow\JobCode'),
26+
new Node\Name\FullyQualified('Kiboko\\Component\\Workflow\\JobCode'),
2727
new Node\Identifier('fromString'),
2828
[
2929
new Node\Arg(new Node\Scalar\String_($code)),
@@ -37,7 +37,7 @@ public function addPipeline(string $code, string $pipelineFilename): self
3737
args: [
3838
new Node\Arg(
3939
new Node\Expr\StaticCall(
40-
new Node\Name\FullyQualified('Kiboko\Component\Workflow\JobCode'),
40+
new Node\Name\FullyQualified('Kiboko\\Component\\Workflow\\JobCode'),
4141
new Node\Identifier('fromString'),
4242
[
4343
new Node\Arg(new Node\Scalar\String_($code)),
@@ -72,7 +72,7 @@ public function addAction(string $code, string $pipelineFilename): self
7272
args: [
7373
new Node\Arg(
7474
new Node\Expr\StaticCall(
75-
new Node\Name\FullyQualified('Kiboko\Component\Workflow\JobCode'),
75+
new Node\Name\FullyQualified('Kiboko\\Component\\Workflow\\JobCode'),
7676
new Node\Identifier('fromString'),
7777
[
7878
new Node\Arg(new Node\Scalar\String_($code)),
@@ -86,7 +86,7 @@ public function addAction(string $code, string $pipelineFilename): self
8686
args: [
8787
new Node\Arg(
8888
new Node\Expr\StaticCall(
89-
new Node\Name\FullyQualified('Kiboko\Component\Workflow\JobCode'),
89+
new Node\Name\FullyQualified('Kiboko\\Component\\Workflow\\JobCode'),
9090
new Node\Identifier('fromString'),
9191
[
9292
new Node\Arg(new Node\Scalar\String_($code)),

src/Builder/Workflow/WorkflowRuntime.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ final class WorkflowRuntime implements Builder
1212
public function getNode(): Node\Expr
1313
{
1414
return new Node\Expr\New_(
15-
class: new Node\Name\FullyQualified('Kiboko\Component\Runtime\Workflow\Console'),
15+
class: new Node\Name\FullyQualified('Kiboko\\Component\\Runtime\\Workflow\\Console'),
1616
args: [
1717
new Node\Arg(
1818
value: new Node\Expr\New_(
@@ -21,7 +21,7 @@ class: new Node\Name\FullyQualified(\Symfony\Component\Console\Output\ConsoleOut
2121
),
2222
new Node\Arg(
2323
new Node\Expr\New_(
24-
class: new Node\Name\FullyQualified('Kiboko\Component\Pipeline\PipelineRunner'),
24+
class: new Node\Name\FullyQualified('Kiboko\\Component\\Pipeline\\PipelineRunner'),
2525
args: [
2626
new Node\Arg(
2727
value: new Node\Expr\New_(

src/Plugin/Batching/Service.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44

55
namespace Kiboko\Component\Satellite\Plugin\Batching;
66

7-
// FIXME: hidden dependency to php-etl/fast-map
87
use Kiboko\Component\SatelliteToolbox\Builder\PropertyPathBuilder;
98
use Kiboko\Component\Satellite\ExpressionLanguage as Satellite;
109
use Kiboko\Component\Satellite\Plugin\Batching\Builder\Fork;

0 commit comments

Comments
 (0)