Also, instead of injecting the container, I injected directly the serializer. I'm not sure how DependencyInjection will behave if the serializer is not installed, although tests are passing.
That being said, I could not write specific tests because I lack knowledge in Mockery, and this is needed to fake a use of the Serializer object.
If you could make tests and correct the service definition if I edited it in the wrong way because of the optional nature of the serializer service, it would be great. Thank you!
I made a mistake in #10. I allowed the usage of the serializer component, but I only implemented it for the first requests, the ones that use Twig.
Because of that, the subsequent requests made with Inertia would not be serialized. To fix this, I had to move the serialization inside the implementation of
InertiaInterface
.Also, instead of injecting the container, I injected directly the serializer. I'm not sure how DependencyInjection will behave if the serializer is not installed, although tests are passing.
That being said, I could not write specific tests because I lack knowledge in Mockery, and this is needed to fake a use of the
Serializer
object.If you could make tests and correct the service definition if I edited it in the wrong way because of the optional nature of the serializer service, it would be great. Thank you!