-
-
Notifications
You must be signed in to change notification settings - Fork 900
fix: Use normalisation context when none is provided in tests #6157
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I tested this change and that resolves the issues I had inside #6146. Thanks @kevin-macquer-omnilog, I hope this gets merged. |
7bf75e3
to
6343acd
Compare
The test that is failing here https://github.com/api-platform/core/actions/runs/7872836937/job/21481776163?pr=6157 is also failing on the main branch in my machine, it doesn't seems linked to those changes. |
we should target 3.2 also is it possible to add a non-reg test in the ApiTestCaseTest? |
Hi soyuka, I'm working on the test today, will post an update when it's done. |
2b62452
to
2707e03
Compare
@soyuka I've added the required tests. For targeting 3.2 it needs to be merged on the main branch right? |
2707e03
to
773f02b
Compare
@soyuka I've changed the target of this PR to 3.2. |
amazing ! |
In #6098 the behavious was changed in the test trait.
Before when you didn't provide a serialization context, the SerializationFactory would initialize it to the normalization context of the operation.
With this change the normalization context is an empty array instead so we loose the normalization context.
Solution: use the normalization context of the operation if the serialization context is null.