@@ -27,14 +27,14 @@ public function testProvide(): void
2727 {
2828 $ objectToPopulate = null ;
2929 $ context = ['args ' => ['input ' => ['test ' ]]];
30- $ operation = new Mutation (class: ' dummy ' );
30+ $ operation = new Mutation (class: \stdClass::class );
3131 $ serializerContext = ['resource_class ' => $ operation ->getClass ()];
3232 $ decorated = $ this ->createMock (ProviderInterface::class);
3333 $ decorated ->expects ($ this ->once ())->method ('provide ' )->willReturn ($ objectToPopulate );
3434 $ denormalizer = $ this ->createMock (DenormalizerInterface::class);
3535 $ serializerContextBuilder = $ this ->createMock (SerializerContextBuilderInterface::class);
3636 $ serializerContextBuilder ->expects ($ this ->once ())->method ('create ' )->with ($ operation ->getClass (), $ operation , $ context , false )->willReturn ($ serializerContext );
37- $ denormalizer ->expects ($ this ->once ())->method ('denormalize ' )->with (['test ' ], ' dummy ' , 'graphql ' , $ serializerContext )->willReturn (new \stdClass ());
37+ $ denormalizer ->expects ($ this ->once ())->method ('denormalize ' )->with (['test ' ], \stdClass::class , 'graphql ' , $ serializerContext )->willReturn (new \stdClass ());
3838 $ provider = new DenormalizeProvider ($ decorated , $ denormalizer , $ serializerContextBuilder );
3939 $ provider ->provide ($ operation , [], $ context );
4040 }
@@ -43,14 +43,14 @@ public function testProvideWithObjectToPopulate(): void
4343 {
4444 $ objectToPopulate = new \stdClass ();
4545 $ context = ['args ' => ['input ' => ['test ' ]]];
46- $ operation = new Mutation (class: ' dummy ' );
46+ $ operation = new Mutation (class: \stdClass::class );
4747 $ serializerContext = ['resource_class ' => $ operation ->getClass (), 'object_to_populate ' => $ objectToPopulate ];
4848 $ decorated = $ this ->createMock (ProviderInterface::class);
4949 $ decorated ->expects ($ this ->once ())->method ('provide ' )->willReturn ($ objectToPopulate );
5050 $ denormalizer = $ this ->createMock (DenormalizerInterface::class);
5151 $ serializerContextBuilder = $ this ->createMock (SerializerContextBuilderInterface::class);
5252 $ serializerContextBuilder ->expects ($ this ->once ())->method ('create ' )->with ($ operation ->getClass (), $ operation , $ context , false )->willReturn ($ serializerContext );
53- $ denormalizer ->expects ($ this ->once ())->method ('denormalize ' )->with (['test ' ], ' dummy ' , 'graphql ' , $ serializerContext )->willReturn (new \stdClass ());
53+ $ denormalizer ->expects ($ this ->once ())->method ('denormalize ' )->with (['test ' ], \stdClass::class , 'graphql ' , $ serializerContext )->willReturn (new \stdClass ());
5454 $ provider = new DenormalizeProvider ($ decorated , $ denormalizer , $ serializerContextBuilder );
5555 $ provider ->provide ($ operation , [], $ context );
5656 }
@@ -59,14 +59,14 @@ public function testProvideNotCalledWithQuery(): void
5959 {
6060 $ objectToPopulate = new \stdClass ();
6161 $ context = ['args ' => ['input ' => ['test ' ]]];
62- $ operation = new Query (class: ' dummy ' );
62+ $ operation = new Query (class: \stdClass::class );
6363 $ serializerContext = ['resource_class ' => $ operation ->getClass ()];
6464 $ decorated = $ this ->createMock (ProviderInterface::class);
6565 $ decorated ->expects ($ this ->once ())->method ('provide ' )->willReturn ($ objectToPopulate );
6666 $ denormalizer = $ this ->createMock (DenormalizerInterface::class);
6767 $ serializerContextBuilder = $ this ->createMock (SerializerContextBuilderInterface::class);
6868 $ serializerContextBuilder ->expects ($ this ->never ())->method ('create ' )->with ($ operation ->getClass (), $ operation , $ context , false )->willReturn ($ serializerContext );
69- $ denormalizer ->expects ($ this ->never ())->method ('denormalize ' )->with (['test ' ], ' dummy ' , 'graphql ' , $ serializerContext )->willReturn (new \stdClass ());
69+ $ denormalizer ->expects ($ this ->never ())->method ('denormalize ' )->with (['test ' ], \stdClass::class , 'graphql ' , $ serializerContext )->willReturn (new \stdClass ());
7070 $ provider = new DenormalizeProvider ($ decorated , $ denormalizer , $ serializerContextBuilder );
7171 $ provider ->provide ($ operation , [], $ context );
7272 }
@@ -75,14 +75,14 @@ public function testProvideNotCalledWithoutDeserialize(): void
7575 {
7676 $ objectToPopulate = new \stdClass ();
7777 $ context = ['args ' => ['input ' => ['test ' ]]];
78- $ operation = new Query (class: ' dummy ' , deserialize: false );
78+ $ operation = new Query (class: \stdClass::class , deserialize: false );
7979 $ serializerContext = ['resource_class ' => $ operation ->getClass ()];
8080 $ decorated = $ this ->createMock (ProviderInterface::class);
8181 $ decorated ->expects ($ this ->once ())->method ('provide ' )->willReturn ($ objectToPopulate );
8282 $ denormalizer = $ this ->createMock (DenormalizerInterface::class);
8383 $ serializerContextBuilder = $ this ->createMock (SerializerContextBuilderInterface::class);
8484 $ serializerContextBuilder ->expects ($ this ->never ())->method ('create ' )->with ($ operation ->getClass (), $ operation , $ context , false )->willReturn ($ serializerContext );
85- $ denormalizer ->expects ($ this ->never ())->method ('denormalize ' )->with (['test ' ], ' dummy ' , 'graphql ' , $ serializerContext )->willReturn (new \stdClass ());
85+ $ denormalizer ->expects ($ this ->never ())->method ('denormalize ' )->with (['test ' ], \stdClass::class , 'graphql ' , $ serializerContext )->willReturn (new \stdClass ());
8686 $ provider = new DenormalizeProvider ($ decorated , $ denormalizer , $ serializerContextBuilder );
8787 $ provider ->provide ($ operation , [], $ context );
8888 }
0 commit comments