33namespace Tests \Torr \SimpleNormalizer \Normalizer ;
44
55use PHPUnit \Framework \Attributes \DataProvider ;
6+ use PHPUnit \Framework \TestCase ;
67use Symfony \Component \DependencyInjection \ServiceLocator ;
78use Tests \Torr \SimpleNormalizer \Fixture \DummyVO ;
89use Torr \SimpleNormalizer \Exception \IncompleteNormalizationException ;
910use Torr \SimpleNormalizer \Normalizer \SimpleNormalizer ;
10- use PHPUnit \Framework \TestCase ;
1111use Torr \SimpleNormalizer \Normalizer \SimpleObjectNormalizerInterface ;
1212use Torr \SimpleNormalizer \Normalizer \Validator \ValidJsonVerifier ;
1313
14- class SimpleNormalizerTest extends TestCase
14+ /**
15+ * @internal
16+ */
17+ final class SimpleNormalizerTest extends TestCase
1518{
1619 /**
1720 *
@@ -40,7 +43,7 @@ public function testJsonVerifierEnabled (callable $call) : void
4043 $ verifier = $ this ->createMock (ValidJsonVerifier::class);
4144
4245 $ verifier
43- ->expects ($ this -> once ())
46+ ->expects (self :: once ())
4447 ->method ('ensureValidOnlyJsonTypes ' );
4548
4649 $ normalizer = new SimpleNormalizer (
@@ -59,7 +62,6 @@ public function testJsonVerifierEnabled (callable $call) : void
5962 ]);
6063 }
6164
62-
6365 /**
6466 *
6567 */
@@ -68,7 +70,7 @@ public function testJsonVerifierDisabled () : void
6870 $ verifier = $ this ->createMock (ValidJsonVerifier::class);
6971
7072 $ verifier
71- ->expects ($ this -> never ())
73+ ->expects (self :: never ())
7274 ->method ('ensureValidOnlyJsonTypes ' );
7375
7476 $ normalizer = new SimpleNormalizer (
@@ -83,7 +85,6 @@ public function testJsonVerifierDisabled () : void
8385 self ::assertTrue (true ); // Just to ensure the test runs without exceptions
8486 }
8587
86-
8788 /**
8889 *
8990 */
@@ -100,7 +101,6 @@ public function testInvalidNormalizer () : void
100101 $ normalizer ->normalize (new DummyVO (42 ));
101102 }
102103
103-
104104 /**
105105 *
106106 */
@@ -124,15 +124,13 @@ public function testInvalidNestedNormalizer () : void
124124 ]);
125125 }
126126
127-
128127 /**
129- *
128+ * @return ServiceLocator<mixed>
130129 */
131130 private function createNormalizerObjectNormalizers (mixed $ returnValue ) : ServiceLocator
132131 {
133132 return new ServiceLocator ([
134- DummyVO::class => static fn () => new readonly class ($ returnValue ) implements SimpleObjectNormalizerInterface
135- {
133+ DummyVO::class => static fn () => new readonly class ($ returnValue ) implements SimpleObjectNormalizerInterface {
136134 public function __construct (
137135 private mixed $ returnValue ,
138136 ) {}
0 commit comments