S
S
Steve2021-08-02 09:45:06
symfony
Steve, 2021-08-02 09:45:06

Problem with xml_serialization?

I have the following problem.
There is jms_serializer.yaml configuration

jms_serializer:
    visitors:
        xml_serialization:
            format_output: '%kernel.debug%'

and there are phpunit tests.

The tests say "Unrecognized option "xml_serialization" under "jms_serializer.visitors". Available options are "json", "xml.""
The site works as it should.

Good. I am replacing xml_serialization in the config with xml.

Now the situation is changing exactly the opposite: the tests no longer give errors, but now the site does not work and writes the error Unrecognized option "xml" under "jms_serializer.visitors". Available options are "json_deserialization", "json_serialization", "xml_deserialization", "xml_serialization".

How to fix it?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Steve, 2021-08-03
@CenterJoin

phpunit tests use the .gitlab-ci.yml config. I used gitlab-runner to run tests through the terminal, BUT ! but when the above error occurred, I changed the configs locally, and if I test with a "runner", then for this you need to have the correct configuration directly on the remote repository

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question