Skip to content

Commit

Permalink
style: use @PHP84Migration ruleset (#2398)
Browse files Browse the repository at this point in the history
## Description

use `@PHP84Migration` ruleset

## What type of PR is this? (check all applicable)
- [ ] Bug Fix
- [ ] Feature
- [ ] Refactor
- [ ] Deprecation
- [ ] Breaking Change
- [ ] Documentation Update
- [ ] CI

## Checklist
- [ ] I have made corresponding changes to the documentation (`docs/`)
- [ ] I have made corresponding changes to the changelog
(`CHANGELOG.md`)
  • Loading branch information
DjordyKoert authored Nov 15, 2024
1 parent 9f6c6a3 commit 9411e9c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 8 deletions.
8 changes: 4 additions & 4 deletions tests/Command/DumpCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@ public function testYaml(): void
'--server-url' => 'http://example.com/api',
]);
$expectedYaml = <<<YAML
servers:
-
url: 'http://example.com/api'
YAML;
servers:
-
url: 'http://example.com/api'
YAML;
self::assertStringContainsString($expectedYaml, $output);
}

Expand Down
12 changes: 8 additions & 4 deletions tests/Model/ModelRegistryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ public function testNameCollisionsAreLogged(Type $type, array $arrayType): void
->expects(self::once())
->method('info')
->with(
'Can not assign a name for the model, the name "ModelRegistryTest" has already been taken.', [
'Can not assign a name for the model, the name "ModelRegistryTest" has already been taken.',
[
'model' => [
'type' => $arrayType,
'options' => [],
Expand All @@ -65,7 +66,8 @@ public function testNameCollisionsAreLogged(Type $type, array $arrayType): void
'extra_context' => true,
],
],
]);
]
);

$registry = new ModelRegistry([], $this->createOpenApi(), []);
$registry->setLogger($logger);
Expand Down Expand Up @@ -124,7 +126,8 @@ public function testNameCollisionsAreLoggedWithAlternativeNames(): void
->expects(self::once())
->method('info')
->with(
'Can not assign a name for the model, the name "ModelRegistryTest" has already been taken.', [
'Can not assign a name for the model, the name "ModelRegistryTest" has already been taken.',
[
'model' => [
'type' => [
'class' => 'Nelmio\\ApiDocBundle\\Tests\\Model\\ModelRegistryTest',
Expand All @@ -151,7 +154,8 @@ public function testNameCollisionsAreLoggedWithAlternativeNames(): void
'groups' => ['group1'],
'serialization_context' => ['groups' => ['group1']],
],
]);
]
);

$registry = new ModelRegistry([], $this->createOpenApi(), $alternativeNames);
$registry->setLogger($logger);
Expand Down

0 comments on commit 9411e9c

Please sign in to comment.