-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[Serializer] Added a test for decoding xml with whitespaces #11233
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
This should probably be done in the branch where the BC was introduced. Edited: looks like it's only in master. |
$this->assertEquals($expected, $this->encoder->decode($xml, 'xml')); | ||
$this->assertEquals( | ||
$expected, | ||
$this->encoder->decode($xml, 'xml', array('xml_decode_ignore_white_space' => true)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if you require passign an option to achieve the same result, it is not BC
The commit 466a3d7 was reverting a BC break |
so I'm -1 for this pR, at least in its current form. It implements a new feature, but reintroduces the previous BC break by default |
I missed the fact that 466a3d7 reverted a BC break. Whitespaces were previously ignored so it works as intended. I've kept the test because none of them contains whitespaces despite the Cdata one (which was part of the confusion). |
👍 now that it only adds an extra test |
👍 |
Thank you @florianv. |
…ces (florianv) This PR was merged into the 2.6-dev branch. Discussion ---------- [Serializer] Added a test for decoding xml with whitespaces | Q | A | ------------- | --- | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | | License | MIT | Doc PR | The PR 466a3d7 introduced a BC break because white spaces were previously decoded as text nodes. So this PR reverts it and adds a context option to configure it. Commits ------- f5bf45e [Serializer] Added a test for decoding xml with whitespaces
The PR 466a3d7 introduced a BC break because white spaces were previously decoded as text nodes.
So this PR reverts it and adds a context option to configure it.