8000 minor #52785 [Serializer] Fix anonymous test class (alexandre-daubois) · symfony/symfony@a5e6f4f · GitHub
[go: up one dir, main page]

Skip to content

Commit a5e6f4f

Browse files
committed
minor #52785 [Serializer] Fix anonymous test class (alexandre-daubois)
This PR was merged into the 6.3 branch. Discussion ---------- [Serializer] Fix anonymous test class | Q | A | ------------- | --- | Branch? | 6.3 | Bug fix? | yes | New feature? | no | Deprecations? | no | Issues | - | License | MIT Fixes failing step on 6.3: https://github.com/symfony/symfony/actions/runs/7029731717/job/19127894554?pr=52771#step:8:2213 Commits ------- 8c45f9f [Serializer] Fix anonymous test class
2 parents eab28dd + 8c45f9f commit a5e6f4f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Symfony/Component/Serializer/Tests/Normalizer/AbstractObjectNormalizerTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -855,7 +855,7 @@ public function testNormalizeWithIgnoreAnnotationAndPrivateProperties()
855855
public function testNormalizeBasedOnAllowedAttributes()
856856
{
857857
$normalizer = new class() extends AbstractObjectNormalizer {
858-
protected function getAllowedAttributes($classOrObject, array $context, bool $attributesAsString = false)
858+
protected function getAllowedAttributes($classOrObject, array $context, bool $attributesAsString = false): array
859859
{
860860
return ['foo'];
861861
}
@@ -865,12 +865,12 @@ protected function extractAttributes(object $object, string $format = null, arra
865865
return [];
866866
}
867867

868-
protected function getAttributeValue(object $object, string $attribute, string $format = null, array $context = [])
868+
protected function getAttributeValue(object $object, string $attribute, string $format = null, array $context = []): mixed
869869
{
870870
return $object->$attribute;
871871
}
872872

873-
protected function setAttributeValue(object $object, string $attribute, $value, string $format = null, array $context = [])
873+
protected function setAttributeValue(object $object, string $attribute, $value, string $format = null, array $context = []): void
874874
{
875875
}
876876
};

0 commit comments

Comments
 (0)
0