Skip to content

Commit

Permalink
Merge pull request #143 from php-etl/fix/rabbit-mq-builder
Browse files Browse the repository at this point in the history
Force composer to search package with compatibility
  • Loading branch information
gplanchat authored Jan 17, 2024
2 parents 249b1a3 + 09c6110 commit 85aaa1f
Show file tree
Hide file tree
Showing 13 changed files with 18 additions and 19 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/quality.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
run: |
wget -q https://cs.symfony.com/download/php-cs-fixer-v3.phar -O php-cs-fixer
chmod a+x php-cs-fixer
PHP_CS_FIXER_IGNORE_ENV=true ./php-cs-fixer fix src --dry-run
./php-cs-fixer fix src --dry-run
phpstan:
runs-on: ubuntu-latest
Expand Down
5 changes: 2 additions & 3 deletions rector.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
declare(strict_types=1);

use Rector\CodeQuality\Rector\Class_\InlineConstructorDefaultToPropertyRector;
use Rector\CodingStyle\Rector\String_\UseClassKeywordForClassNameResolutionRector;
use Rector\Config\RectorConfig;
use Rector\Php55\Rector\String_\StringClassNameToClassConstantRector;
use Rector\Set\ValueObject\LevelSetList;
Expand All @@ -22,7 +23,5 @@
SymfonyLevelSetList::UP_TO_SYMFONY_60,
]);

$rectorConfig->skip([
StringClassNameToClassConstantRector::class
]);
$rectorConfig->skip([StringClassNameToClassConstantRector::class]);
};
2 changes: 1 addition & 1 deletion src/Action/SFTP/Builder/Action.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function withState(Node\Expr $state): self
public function getNode(): Node
{
return new Node\Expr\New_(
class: new Node\Name\FullyQualified('Kiboko\Component\Action\Flow\SFTP\UploadFile'),
class: new Node\Name\FullyQualified('Kiboko\\Component\\Action\\Flow\\SFTP\\UploadFile'),
args: [
new Node\Arg(
value: $this->host,
Expand Down
2 changes: 1 addition & 1 deletion src/Feature/Rejection/Builder/Rejection.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public function withRejection(Node\Expr $rejection): void
private static function nullRejection(): Node\Expr
{
return new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullRejection::class)
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullRejection')
);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public function __construct(private readonly Rejection\Builder\RabbitMQBuilder $
{
$this->files = [];
$this->packages = [
'php-etl/rabbitmq-flow',
'php-etl/rabbitmq-flow:*',
];
}

Expand Down
4 changes: 2 additions & 2 deletions src/Pipeline/Loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function __invoke(array $config, Pipeline $pipeline, StepRepositoryInterf
$rejection = $compiled->getBuilder()->getNode();
} else {
$rejection = new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullStepRejection::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullStepRejection'),
);
}

Expand All @@ -62,7 +62,7 @@ public function __invoke(array $config, Pipeline $pipeline, StepRepositoryInterf
$state = $compiled->getBuilder()->getNode();
} else {
$state = new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullStepState::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullStepState'),
);
}

Expand Down
4 changes: 2 additions & 2 deletions src/Pipeline/Transformer.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function __invoke(array $config, Pipeline $pipeline, StepRepositoryInterf
$rejection = $compiled->getBuilder()->getNode();
} else {
$rejection = new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullStepRejection::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullStepRejection'),
);
}

Expand All @@ -62,7 +62,7 @@ public function __invoke(array $config, Pipeline $pipeline, StepRepositoryInterf
$state = $compiled->getBuilder()->getNode();
} else {
$state = new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullStepState::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullStepState'),
);
}

Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/Batching/Builder/Fork.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class: new Node\Stmt\Class_(
name: null,
subNodes: [
'implements' => [
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface::class'),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface'),
],
'stmts' => [
new Node\Stmt\ClassMethod(
Expand Down
6 changes: 3 additions & 3 deletions src/Plugin/Batching/Builder/Merge.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ class: new Node\Stmt\Class_(
name: null,
subNodes: [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\TransformerInterface::class),
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\FlushableInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface'),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\FlushableInterface'),
],
'stmts' => [
new Node\Stmt\Property(
Expand Down Expand Up @@ -226,7 +226,7 @@ class: new Node\Name\FullyQualified('Kiboko\\Component\\Bucket\\AcceptanceResult
)
),
],
'returnType' => new Node\Name\FullyQualified(\Kiboko\Contract\Bucket\ResultBucketInterface::class),
'returnType' => new Node\Name\FullyQualified('Kiboko\\Contract\\Bucket\\ResultBucketInterface'),
],
),
],
Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/Filtering/Builder/Drop.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public function getNode(): Node
return new Node\Expr\New_(
class: new Node\Stmt\Class_(null, [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\TransformerInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface'),
],
'stmts' => [
(new Builder\Method('transform'))
Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/Filtering/Builder/Reject.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public function getNode(): Node
return new Node\Expr\New_(
class: new Node\Stmt\Class_(null, [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\TransformerInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface'),
],
'stmts' => [
(new Builder\Method('transform'))
Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/SFTP/Builder/Extractor.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ class: new Node\Stmt\Class_(
name: null,
subNodes: [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\LoaderInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\LoaderInterface'),
],
'stmts' => [
new Node\Stmt\ClassMethod(
Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/SFTP/Builder/Loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ class: new Node\Stmt\Class_(
name: null,
subNodes: [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\LoaderInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\LoaderInterface'),
],
'stmts' => [
new Node\Stmt\ClassMethod(
Expand Down

0 comments on commit 85aaa1f

Please sign in to comment.